]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/web/templates/default/apache.frontend.erb
Disable HSTS for Firefox 52 to avoid issues with remote editing
[chef.git] / cookbooks / web / templates / default / apache.frontend.erb
index 2058b7a98ee25ce3dd8ca103e7d9cd12e76da30c..b2bf38a2e376b6455652fb42ad7ed6209d46ce7f 100644 (file)
   SSLProxyEngine on
   SSLCertificateFile /etc/ssl/certs/www.openstreetmap.org.pem
   SSLCertificateKeyFile /etc/ssl/private/www.openstreetmap.org.key
+
+  #
+  # Disable HSTS for Firefox 52 to avoid issues with remote editing
+  #
+  BrowserMatch Firefox/52 no-hsts
+  Header set Strict-Transport-Security "max-age=0" env=no-hsts
 <% end -%>
 
   #
   ServerName openstreetmap.org
   ServerAlias *
 
-  RedirectPermanent / https://www.openstreetmap.org/
+  RewriteEngine on
+
+  RewriteCond %{REQUEST_URI} !^/server-status$
+  RewriteRule ^(.*)$ https://www.openstreetmap.org$1 [L,NE,R=permanent]
 </VirtualHost>
 
 <VirtualHost *:443>