Load Balancer for GitLab HA
In an active/active GitLab configuration, you will need a load balancer to route traffic to the application servers. The specifics on which load balancer to use or the exact configuration is beyond the scope of GitLab documentation. We hope that if you're managing HA systems like GitLab you have a load balancer of choice already. Some examples including HAProxy (open-source), F5 Big-IP LTM, and Citrix Net Scaler. This documentation will outline what ports and protocols you need to use with GitLab.
Basic ports
LB Port | Backend Port | Protocol |
---|---|---|
80 | 80 | HTTP |
443 | 443 | TCP or HTTPS |
22 | 22 | TCP |
GitLab Pages Ports
If you're using GitLab Pages with custom domain support you will need some
additional port configurations.
GitLab Pages requires a separate virtual IP address. Configure DNS to point the
pages_external_url
from /etc/gitlab/gitlab.rb
at the new virtual IP address. See the
GitLab Pages documentation for more information.
LB Port | Backend Port | Protocol |
---|---|---|
80 | Varies | HTTP |
443 | Varies | TCP |
Alternate SSH Port
Some organizations have policies against opening SSH port 22. In this case, it may be helpful to configure an alternate SSH hostname that allows users to use SSH on port 443. An alternate SSH hostname will require a new virtual IP address compared to the other GitLab HTTP configuration above.
Configure DNS for an alternate SSH hostname such as altssh.gitlab.example.com.
LB Port | Backend Port | Protocol |
---|---|---|
443 | 22 | TCP |
Read more on high-availability configuration: