I'm using GitLab Omnibus on a CentOS6.5 server.
The gitlab nginx server listen on the 6543 port (Apache already using 80 and 443).
I want to use Apache as a reverse proxy to access GitLab with that address: gitlab.example.com instead of example.com:6543
So I add an Apache Virtual Host, here is the configuration:
<IfModule mod_ssl.c>
<VirtualHost *:443>
ServerAdmin admin@example.com
ServerName gitlab.example.com
ServerSignature Off
CustomLog /var/log/httpd/gitlab_access.log combined
ErrorLog /var/log/httpd/gitlab_error.log
ErrorLog syslog:local2
<IfModule mod_proxy.c>
ProxyVia On
ProxyRequests Off
ProxyPass / https://example.com:6543/
ProxyPassReverse / https://example.com:6543/
ProxyPreserveHost Off
<Proxy *>
Options FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Proxy>
</IfModule>
# SSL Config
SSLCertificateFile /etc/ssl/example.com/default.crt
SSLCertificateKeyFile /etc/ssl/example.com/default.key
SSLEngine on
SSLProtocol all -SSLv2
SSLHonorCipherOrder on
SSLCipherSuite ALL:!aNULL:!eNULL:!LOW:!EXP:!RC4:!3DES:+HIGH:+MEDIUM
Header set Strict-Transport-Security "max-age=2678400"
</VirtualHost>
</IfModule>
<VirtualHost *:80>
ServerName gitlab.example.com
Redirect / https://gitlab.example.com:443
</VirtualHost>
So gitlab and apache are running, but when trying to access gitlab via the proxy server, it fails and output a 500 error.
How can I make this work?