[go: up one dir, main page]

ENV["RAILS_RELATIVE_URL_ROOT"] is not set for Sidekiq

This came from gitlab-org/gitlab-ce#26539. Unicorn sets ENV["RAILS_RELATIVE_URL_ROOT"] here, but Sidekiq doesn't get this setting so notification e-mails (e.g. ones that use image_url) don't have the proper relative URLs:

For example, assuming your relative URL path is /gitlab, you can temporarily fix this by doing:

sudo echo "/gitlab" > /opt/gitlab/etc/gitlab-rails/env/RAILS_RELATIVE_URL_ROOT
sudo gitlab-ctl restart sidekiq

You have to be sure to remove this file out if the relative URL root goes away. I believe env_dir handles this for us already.