|
@@ -0,0 +1,36 @@
|
|
1
|
+<VirtualHost *:80>
|
|
2
|
+ ServerName {{ cgit_domain }}
|
|
3
|
+
|
|
4
|
+ Redirect permanent / https://{{ cgit_domain }}/
|
|
5
|
+</VirtualHost>
|
|
6
|
+
|
|
7
|
+<VirtualHost *:443>
|
|
8
|
+ ServerName {{ cgit_domain }}
|
|
9
|
+
|
|
10
|
+ SSLEngine on
|
|
11
|
+ SSLProtocol ALL -SSLv2
|
|
12
|
+ SSLHonorCipherOrder On
|
|
13
|
+ SSLCipherSuite ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AES:RSA+3DES:!ADH:!AECDH:!MD5:!DSS
|
|
14
|
+ SSLCertificateFile /etc/ssl/certs/wildcard_public_cert.crt
|
|
15
|
+ SSLCertificateKeyFile /etc/ssl/private/wildcard_private.key
|
|
16
|
+ SSLCACertificateFile /etc/ssl/certs/wildcard_ca.pem
|
|
17
|
+ Header add Strict-Transport-Security "max-age=15768000; includeSubdomains"
|
|
18
|
+
|
|
19
|
+ DocumentRoot /var/www/htdocs/cgit/
|
|
20
|
+
|
|
21
|
+ <Directory "/var/www/htdocs/cgit/">
|
|
22
|
+ AllowOverride None
|
|
23
|
+ Options +ExecCGI
|
|
24
|
+ Order allow,deny
|
|
25
|
+ Allow from all
|
|
26
|
+ </Directory>
|
|
27
|
+
|
|
28
|
+ Alias /cgit.png /var/www/htdocs/cgit/cgit.png
|
|
29
|
+ Alias /cgit.css /var/www/htdocs/cgit/cgit.css
|
|
30
|
+ ScriptAlias / /var/www/htdocs/cgit/cgit.cgi/
|
|
31
|
+ RewriteRule ^$ / [R]
|
|
32
|
+ RewriteRule ^/(.*)$ /cgit.cgi/$1 [PT]
|
|
33
|
+
|
|
34
|
+ CustomLog /var/log/apache2/cgit_access.log combined
|
|
35
|
+ ErrorLog /var/log/apache2/cgit_error.log
|
|
36
|
+</VirtualHost>
|