What I already have
I have a GitLab CE instance running on a server with a domain name that I want: let’s call it
domain1.org. I used Let’s Encrypt to fetch a TLS certificate, and edited the gitlab.rb configuration file to add that cert to the nginx.conf file that GitLab generates. All that’s working, that’s not a problem.
What I’m trying to do
That server running the GitLab CE instance is accessible via 2 domains. I know nginx can be configured to serve as a reverse proxy for multiple domains (I’m doing it on another server with some other sites). However, the gitlab.rb configuration file doesn’t seem to make it possible to do this.
I have certs for both domains, I just don’t know how to serve both sites through nginx that gets configured by GitLab.
I could probably edit the
/var/opt/gitlab/nginx/conf files to serve the other cert for
domain2.org, but I’m afraid that GitLab will simply wipe out and re-generate the configuration files when it gets reconfigured.
Has anyone tried to do this before successfully? Any tips would be appreciated.