Updating mod_rewrite expression for SERVER_NAME

Also changed the ca.crt example name to be more intuitive.
This commit is contained in:
Sam Gleske
2013-09-11 13:52:17 -04:00
parent 0d3075dc40
commit 417d227e91

View File

@@ -8,10 +8,11 @@
# mod_proxy_http
<VirtualHost *:80>
ServerName gitlab.example.com
ServerSignature Off
RewriteEngine on
RewriteCond %{HTTPS} !=on
RewriteRule ^(.*) https://gitlab.example.com$1 [R,L]
RewriteRule ^(.*) https://%{SERVER_NAME}$1 [R,L]
</VirtualHost>
<VirtualHost *:443>
SSLEngine on
@@ -20,7 +21,7 @@
SSLCertificateKeyFile /etc/httpd/ssl.key/gitlab.example.com.key
SSLCACertificateFile /etc/httpd/ssl.crt/incommon-ca.crt
ServerName gitlab.example.com
ServerName gitlab.example.com
ServerSignature Off
#apache equivalent of nginx try files
@@ -41,7 +42,7 @@
</Proxy>
# needed for downloading attachments
DocumentRoot /app/gitlab/gitlab/public
DocumentRoot /home/git/gitlab/public
<Location />
Order deny,allow