Gitlab and Apache as reverse proxy
Submitted by itefix on Wed, 04/01/2023 - 00:17
- Apache site with Letsencrypt certificate and access restrictions for some hosts/ips. Gitlab server's ip is 3.3.3.3
<IfModule mod_ssl.c>
<VirtualHost *:443>
ServerName git.domain.com
CustomLog ${APACHE_LOG_DIR}/git_access.log vhost_combined
ProxyRequests off
<Location />
Require host my.domain.com your.domain.com
Require ip 1.1.1.1 2.2.2.0/24
ProxyPass "http://3.3.3.3/" retry=0
ProxyPassReverse "http://3.3.3.3/"
</Location>
SSLCertificateFile /etc/letsencrypt/live/git.domain.com/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/git.domain.com/privkey.pem
Include /etc/letsencrypt/options-ssl-apache.conf
</VirtualHost>
</IfModule>
- Specify http://git.domain.com as external domain before Gitlab installation:
sudo EXTERNAL_URL="http://git.domain.com" .....
Featured product
Free Software Highlights
Release Announcements
- 2024-11-25 Copssh client 8.0.0
- 2024-11-17 OpenSSL tool 2.0.1
- 2024-11-17 Wrbldnsd 5.0.2