Commit 1d1c11164739ad6bb3bba176316f15e7b78a33b6
1 parent
a98e398c
Exists in
master
Change the permissions of gitlab-rails dir, change location of the sockets directory.
Showing
2 changed files
with
14 additions
and
2 deletions
Show diff stats
files/gitlab-cookbooks/gitlab/attributes/default.rb
| ... | ... | @@ -158,7 +158,7 @@ default['gitlab']['unicorn']['log_directory'] = "/var/log/gitlab/unicorn" |
| 158 | 158 | default['gitlab']['unicorn']['worker_processes'] = 2 |
| 159 | 159 | default['gitlab']['unicorn']['listen'] = '127.0.0.1' |
| 160 | 160 | default['gitlab']['unicorn']['port'] = 8080 |
| 161 | -default['gitlab']['unicorn']['socket'] = '/var/opt/gitlab/gitlab-rails/tmp/sockets/gitlab.socket' | |
| 161 | +default['gitlab']['unicorn']['socket'] = '/var/opt/gitlab/gitlab-rails/sockets/gitlab.socket' | |
| 162 | 162 | default['gitlab']['unicorn']['pidfile'] = '/opt/gitlab/var/unicorn/unicorn.pid' |
| 163 | 163 | default['gitlab']['unicorn']['tcp_nopush'] = true |
| 164 | 164 | default['gitlab']['unicorn']['backlog_socket'] = 64 | ... | ... |
files/gitlab-cookbooks/gitlab/recipes/gitlab-rails.rb
| ... | ... | @@ -26,7 +26,6 @@ gitlab_rails_public_uploads_dir = node['gitlab']['gitlab-rails']['uploads_direct |
| 26 | 26 | gitlab_rails_log_dir = node['gitlab']['gitlab-rails']['log_directory'] |
| 27 | 27 | |
| 28 | 28 | [ |
| 29 | - gitlab_rails_dir, | |
| 30 | 29 | gitlab_rails_etc_dir, |
| 31 | 30 | gitlab_rails_env_dir, |
| 32 | 31 | gitlab_rails_working_dir, |
| ... | ... | @@ -43,6 +42,19 @@ gitlab_rails_log_dir = node['gitlab']['gitlab-rails']['log_directory'] |
| 43 | 42 | end |
| 44 | 43 | end |
| 45 | 44 | |
| 45 | +directory gitlab_rails_dir do | |
| 46 | + owner node['gitlab']['user']['username'] | |
| 47 | + mode '0755' | |
| 48 | + recursive true | |
| 49 | +end | |
| 50 | + | |
| 51 | +directory File.join(gitlab_rails_dir, "sockets") do | |
| 52 | + owner node['gitlab']['user']['username'] | |
| 53 | + group node['gitlab']['web_server']['username'] | |
| 54 | + mode '0770' | |
| 55 | + recursive true | |
| 56 | +end | |
| 57 | + | |
| 46 | 58 | dependent_services = [] |
| 47 | 59 | dependent_services << "service[unicorn]" if OmnibusHelper.should_notify?("unicorn") |
| 48 | 60 | dependent_services << "service[sidekiq]" if OmnibusHelper.should_notify?("sidekiq") | ... | ... |