]> git.donarmstrong.com Git - dsa-puppet.git/commitdiff
Try new www vhost config
authorPeter Palfrader <peter@palfrader.org>
Wed, 1 Jan 2014 21:55:40 +0000 (22:55 +0100)
committerPeter Palfrader <peter@palfrader.org>
Wed, 1 Jan 2014 21:55:40 +0000 (22:55 +0100)
modules/roles/templates/apache-www.debian.org.erb

index a4a4e8dc2cbfdc0b8f8b9466acf9caba65ad1255..aee7380b1612f3386ac26c1b4c7eacd61cf99ce2 100644 (file)
    RewriteRule ^/(.*)$ http://www.debian.org/$1 [R=301,L]
 </VirtualHost>
 
-<VirtualHost <%= vhost_listen %> >
+
+
+<Macro common-www.d.o>
    ServerName www.debian.org
    ServerAdmin webmaster@debian.org
    ServerAlias www-*.debian.org
 # Canonical place for manuals under /doc/manuals/
    RewriteCond %{DOCUMENT_ROOT}/doc/manuals/$1 -d
    RewriteRule ^/doc/([^/]+)/?(.*)? /doc/manuals/$1/$2 [L,R=301]
+</Macro>
+
+
+<VirtualHost <%= vhost_listen %> >
+   Use common-www.d.o
+</VirtualHost>
+<VirtualHost <%= vhost_listen_443 %> >
+   Use common-www.d.o
+
+   Use common-debian-service-ssl www.debian.org
+   Use common-ssl-HSTS
+</VirtualHost>
+
+
+<VirtualHost <%= vhost_listen_443 %> >
+   ServerName debian.org
+   ServerAdmin webmaster@debian.org
+
+   CustomLog /var/log/apache2/www-other-access.log privacy
+   ErrorLog /var/log/apache2/www-other-error.log
+
+   Redirect permanent / https://www.debian.org/
 
+   Use common-debian-service-ssl www.debian.org
+   Use common-ssl-HSTS
 </VirtualHost>