Skip to content
Snippets Groups Projects
Commit 54fcd297 authored by DJ Mountney's avatar DJ Mountney
Browse files

Merge branch '3483-symlink-g' into 'master'

Resolve "Geo: Create an alias to connect to the Geo tracking DB via psql"

Closes #3483

See merge request gitlab-org/omnibus-gitlab!2487
parents 7727873a 2a0e9efd
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -110,6 +110,17 @@ could not change directory to "/root"
 
This is normal behavior and it can be ignored.
 
#### Starting a Postgres superuser psql session in Geo tracking database
Similar to the previous command, if you need superuser access to the bundled
Geo tracking database (`geo-postgresql`), you can use the `gitlab-geo-psql`.
It takes the same arguments as the regular `psql` command.
```shell
# Superuser psql access to GitLab's Geo tracking database
sudo gitlab-geo-psql -d gitlabhq_geo_production
```
### Container registry garbage collection
 
Container registry can use considerable amounts of disk space. To clear up
Loading
Loading
#!/bin/sh
#!/bin/bash
#
# Symlink the ctl commands
DEST_DIR=${1:-/opt/gitlab}
 
usr_bin_symlinks="\
${DEST_DIR}/bin/gitlab-ctl \
${DEST_DIR}/bin/gitlab-rake \
${DEST_DIR}/bin/gitlab-rails \
${DEST_DIR}/bin/gitlab-psql \
"
symlink_command="ln -sf ${usr_bin_symlinks} /usr/bin/"
usr_bin_symlinks=(
"${DEST_DIR}/bin/gitlab-ctl"
"${DEST_DIR}/bin/gitlab-rake"
"${DEST_DIR}/bin/gitlab-rails"
"${DEST_DIR}/bin/gitlab-psql"
"${DEST_DIR}/bin/gitlab-geo-psql"
)
 
error_exit()
{
Loading
Loading
@@ -19,7 +19,12 @@ error_exit()
 
create_symlinks()
{
${symlink_command} || error_exit "Failed to create symlinks in /usr/bin"
for symlink in "${usr_bin_symlinks[@]}"
do
if [ -f $symlink ]; then
ln -sf $symlink /usr/bin || error_exit "Failed to create symlinks in /usr/bin"
fi
done
}
 
create_symlinks
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment