Commit b1a1863b9eb58218a6c1129062d8dd8174b1b8c5

Authored by Jacob Vosmaer
1 parent 965b2b7e

Correctly set HOME for Unicorn and Sidekiq

This fixes a bug where ~git/.gitconfig was being ignored, leading to
CRLF problems in web edits.
CHANGELOG
... ... @@ -6,6 +6,7 @@
6 6 - Correct default gravatar configuration (#112) (Julien Pivotto)
7 7 - Update Ruby to 2.0.0p451
8 8 - Fix name clash between release.sh and `make release`
  9 +- Fix Git CRLF bug
9 10  
10 11 6.8.1
11 12 - Use gitlab-rails 6.8.1
... ...
files/gitlab-cookbooks/gitlab/templates/default/sv-sidekiq-run.erb
... ... @@ -3,4 +3,4 @@
3 3 cd <%= node['gitlab']['gitlab-rails']['dir'] %>/working
4 4  
5 5 exec 2>&1
6   -exec chpst -P -U <%= node['gitlab']['user']['username'] %> -u <%= node['gitlab']['user']['username'] %> /usr/bin/env BUNDLE_GEMFILE=/opt/gitlab/embedded/service/gitlab-rails/Gemfile HOME="<%= node['gitlab']['gitlab-rails']['dir'] %>" /opt/gitlab/embedded/bin/bundle exec sidekiq -q post_receive,mailer,system_hook,project_web_hook,gitlab_shell,common,default -e <%= node['gitlab']['gitlab-rails']['environment'] %> -r /opt/gitlab/embedded/service/gitlab-rails
  6 +exec chpst -P -U <%= node['gitlab']['user']['username'] %> -u <%= node['gitlab']['user']['username'] %> /usr/bin/env BUNDLE_GEMFILE=/opt/gitlab/embedded/service/gitlab-rails/Gemfile HOME="<%= node['gitlab']['user']['home'] %>" /opt/gitlab/embedded/bin/bundle exec sidekiq -q post_receive,mailer,system_hook,project_web_hook,gitlab_shell,common,default -e <%= node['gitlab']['gitlab-rails']['environment'] %> -r /opt/gitlab/embedded/service/gitlab-rails
... ...
files/gitlab-cookbooks/gitlab/templates/default/sv-unicorn-run.erb
... ... @@ -3,4 +3,4 @@
3 3 cd /opt/gitlab/embedded/service/gitlab-rails
4 4  
5 5 exec 2>&1
6   -exec chpst -P -U <%= node['gitlab']['user']['username'] %> -u <%= node['gitlab']['user']['username'] %> /usr/bin/env HOME="<%= node['gitlab']['gitlab-rails']['dir'] %>" /opt/gitlab/embedded/bin/bundle exec unicorn -E <%= node['gitlab']['gitlab-rails']['environment'] %> -c <%= File.join(node['gitlab']['gitlab-rails']['dir'], "etc", "unicorn.rb") %> /opt/gitlab/embedded/service/gitlab-rails/config.ru
  6 +exec chpst -P -U <%= node['gitlab']['user']['username'] %> -u <%= node['gitlab']['user']['username'] %> /usr/bin/env HOME="<%= node['gitlab']['user']['home'] %>" /opt/gitlab/embedded/bin/bundle exec unicorn -E <%= node['gitlab']['gitlab-rails']['environment'] %> -c <%= File.join(node['gitlab']['gitlab-rails']['dir'], "etc", "unicorn.rb") %> /opt/gitlab/embedded/service/gitlab-rails/config.ru
... ...