I’m using GitLab CE Omnibus 10.7.3.
According to https://docs.gitlab.com/omnibus/settings/configuration.html, in order to put GitLab into a relative URL, I just need to modify
/etc/gitlab/gitlab.rb, followed by
sudo gitlab-ctl reconfigure and
sudo gitlab-ctl restart.
And the following was my
... external_url 'https://dev.mydomain.com/gitlab' ...
After reconfigure and restart, it indeed worked flawlessly.
But things go wrong after a reboot of the machine. I noticed that
gitlab.rb was automatically reverted to
http://xxx.xxx.xxx.xxx whenever the server gets restarted, where
xxx.xxx.xxx.xxx is the intranet IP address of the server.
As my intranet server is accessed from external via a port forwarding setting on the gateway, it is understandable the the intranet server will not be able to tell its public domain name, nor would it be able to tell the relative URL that I want to put it under.
So, my questions is, how do I lock down the
external_url configuration in
gitlab.rb, so that it doesn’t revert to IP address without relative URL upon every server restart? I searched on SO and on Google, but I have not been able to find any lead on locking down the setting. The only thing related I found was about deploying GitLab Omnibus on AWS, but it didn’t talk about locking in the relative URL, either.
Is there anything that I missed on setting GitLab Omnibus up for relative URL?