Commit 835077694b76e9d75f4c2f74304bb5dba8fc43c1
1 parent
8d109800
Exists in
master
and in
17 other branches
Factor out the install_dir in bundle_exec_wrapper
Showing
2 changed files
with
5 additions
and
5 deletions
Show diff stats
config/software/gitlab-core.rb
config/templates/gitlab-core/bundle_exec_wrapper.erb
1 | 1 | #!/bin/bash |
2 | -export PATH=/opt/gitlab/bin:/opt/gitlab/embedded/bin:$PATH | |
2 | +export PATH=<%= @install_dir %>/bin:<%= @install_dir %>/embedded/bin:$PATH | |
3 | 3 | |
4 | 4 | # default to RAILS_ENV=production |
5 | 5 | if [[ -z $RAILS_ENV ]]; then |
6 | 6 | export RAILS_ENV=production |
7 | 7 | fi |
8 | 8 | |
9 | -gitlab_user=$(ls -lLd /opt/gitlab/embedded/service/gitlab-core/log | awk '{ print $3 }') | |
9 | +gitlab_user=$(ls -lLd <%= @install_dir %>/embedded/service/gitlab-core/log | awk '{ print $3 }') | |
10 | 10 | |
11 | -cd /opt/gitlab/embedded/service/gitlab-core | |
12 | -/opt/gitlab/embedded/bin/chpst -u $gitlab_user -U $gitlab_user /opt/gitlab/embedded/bin/bundle exec <%= @command %> | |
11 | +cd <%= @install_dir %>/embedded/service/gitlab-core | |
12 | +<%= @install_dir %>/embedded/bin/chpst -u $gitlab_user -U $gitlab_user <%= @install_dir %>/embedded/bin/bundle exec <%= @command %> | ... | ... |