I'm using GitLab Community Edition 8.6.6 6d3805b, installed on the machine gitlab.somedomain.com
. But users can access to this machine only through DNS server git-remote.somedomain.com
.
All repositories in GitLab have such URLs:
- ssh:
git@gitlab.somedomain.com:username/projectname.git
- https:
http://gitlab.somedomain.com:9336/username/projectname.git
(I use port 9336 because there are many others web-services installed on this machine) And users can't clone, push or pull in repositories through DNS because it has different hostname.
I tried to change hostname for git as following:
- Changed the
external_url
in/etc/gitlab/gitlab.rb
fromgitlab.somedomain.com:9336
togit-remote.somedomain.com
. - Removed data of the previous hostname using
rm -rf /opt/gitlab/embedded/nodes
. - Reconfigured GitLab service using
gitlab-ctl reconfigure
.
But GitLab web-ui gave me the following error:
The service temporary unavailable.
However gitlab-ctl status is ok:
:~# gitlab-ctl status
run: gitlab-workhorse: (pid 12940) 1464228s; run: log: (pid 442) 1503945s
run: logrotate: (pid 12560) 2557s; run: log: (pid 444) 1503945s
run: nginx: (pid 13061) 2402s; run: log: (pid 445) 1503945s
run: postgresql: (pid 12970) 1464226s; run: log: (pid 440) 1503945s
run: redis: (pid 12972) 1464225s; run: log: (pid 438) 1503945s
run: sidekiq: (pid 13052) 2402s; run: log: (pid 441) 1503945s
run: unicorn: (pid 13131) 2379s; run: log: (pid 439) 1503945s
How can I adjust GitLab to make it running correctly through DNS?
P.S. I can't change the hostname of gitlab.somedomain.com
because there are many services installed on it. I also can't rename DNS server because I haven't enough rights.