I am trying to setup my ubuntu server to allow for website hosting using NGinx, MySQL, and PHP. I would like example.com to point to my website on port 80.
I would also like gitlab.example.com to load the gitlab web app. Since gitlab by default also uses port 80 or 443, I need to change gitlabs port.
I have not installed gitlab yet because I am unsure how I should accomplish this.
I have read online that you can just enter the port in the external_url like so:
sudo EXTERNAL_URL="https://gitlab.example.com:8111" apt-get install gitlab-ee
But will this automatically work for Lets Encrypt?
I want to be able to access gitlab by visiting https://gitlab.example.com without the port. Is this posible like this?
If not, can I configure nginx to redirect all port 80 traffic from gitlab.example.com to the proper port on the machine?
server {
listen 80;
listen 443;
server_name gitlab.example.com;
location / {
proxy_pass https://localhost:8111;
}
}
I am lost on this and I cannot find documentation that covers my specific scenario.
Thanks for any help!