]> git.openstreetmap.org Git - chef.git/blob - cookbooks/cgiirc/templates/default/apache.erb
Enable SSL for irc.osm.org
[chef.git] / cookbooks / cgiirc / templates / default / apache.erb
1 # DO NOT EDIT - This file is being maintained by Chef
2
3 <VirtualHost *:443>
4         ServerName <%= @name %>
5         ServerAdmin webmaster@openstreetmap.org
6
7         SSLEngine on
8         SSLCertificateFile /etc/ssl/certs/<%= @name %>.pem
9         SSLCertificateKeyFile /etc/ssl/private/<%= @name %>.key
10
11         CustomLog /var/log/apache2/<%= @name %>-access.log combined
12         ErrorLog /var/log/apache2/<%= @name %>-error.log
13
14         DocumentRoot /usr/lib/cgi-bin/cgiirc
15         DirectoryIndex irc.cgi
16         Alias /images /usr/share/images/cgiirc
17
18         <Directory "/usr/lib/cgi-bin/cgiirc">
19                 AddHandler cgi-script .cgi
20                 Require all granted
21         </Directory>
22
23         <Directory "/usr/share/images/cgiirc">
24                 Require all granted
25         </Directory>
26
27         <IfModule mod_deflate.c>
28                 RemoveOutputFilter DEFLATE
29                 SetEnv no-gzip
30         </IfModule>
31 </VirtualHost>
32
33 <VirtualHost *:80>
34         ServerName <%= @name %>
35         ServerAdmin webmaster@openstreetmap.org
36
37         CustomLog /var/log/apache2/<%= @name %>-access.log combined
38         ErrorLog /var/log/apache2/<%= @name %>-error.log
39
40         RedirectPermanent /.well-known/acme-challenge/ http://acme.openstreetmap.org/.well-known/acme-challenge/
41         RedirectPermanent / https://<%= @name %>/
42 </VirtualHost>