diff --git a/config/software/gitlab-rails.rb b/config/software/gitlab-rails.rb index 5e3ae58..a0a8557 100644 --- a/config/software/gitlab-rails.rb +++ b/config/software/gitlab-rails.rb @@ -81,6 +81,10 @@ build do # Remove directories that will be created by `gitlab-ctl reconfigure` command "rm -rf log tmp public/uploads" + # Create symbolik link for assets + command "mkdir public/gitlab" + command "ln -s ../assets/ public/gitlab" + # Because db/schema.rb is modified by `rake db:migrate` after installation, # keep a copy of schema.rb around in case we need it. (I am looking at you, # mysql-postgresql-converter.) diff --git a/files/gitlab-cookbooks/gitlab/templates/default/gitlab.yml.erb b/files/gitlab-cookbooks/gitlab/templates/default/gitlab.yml.erb index ca2f2f5..d949b72 100644 --- a/files/gitlab-cookbooks/gitlab/templates/default/gitlab.yml.erb +++ b/files/gitlab-cookbooks/gitlab/templates/default/gitlab.yml.erb @@ -21,7 +21,7 @@ production: &base # 2) In your gitlab.yml file: relative_url_root: /gitlab # 3) In your unicorn.rb: ENV['RAILS_RELATIVE_URL_ROOT'] = "/gitlab" # 4) In ../gitlab-shell/config.yml: gitlab_url: "http://127.0.0.1/gitlab" - # relative_url_root: /gitlab + relative_url_root: /gitlab # Uncomment and customize if you can't use the default user to run GitLab (default: 'git') user: <%= node['gitlab']['user']['username'] %> diff --git a/files/gitlab-cookbooks/gitlab/templates/default/unicorn.rb.erb b/files/gitlab-cookbooks/gitlab/templates/default/unicorn.rb.erb index 4c5806f..973ab9c 100644 --- a/files/gitlab-cookbooks/gitlab/templates/default/unicorn.rb.erb +++ b/files/gitlab-cookbooks/gitlab/templates/default/unicorn.rb.erb @@ -2,6 +2,7 @@ # erased! To change the contents below, edit /etc/gitlab/gitlab.rb # and run `sudo gitlab-ctl reconfigure`. +ENV['RAILS_RELATIVE_URL_ROOT'] = "/gitlab" # What ports/sockets to listen on, and what options for them. <%- @listen.each do |port, options| %> -- libgit2 0.21.2