X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/ab47927c016597f8602b81dcdc168ad5c335389d..91f61bf7bb78738f8b15a8b0b8adff00caf4ac8d:/cookbooks/osqa/templates/default/apache.erb?ds=sidebyside diff --git a/cookbooks/osqa/templates/default/apache.erb b/cookbooks/osqa/templates/default/apache.erb index 9aa0eb9cb..1ef85c040 100644 --- a/cookbooks/osqa/templates/default/apache.erb +++ b/cookbooks/osqa/templates/default/apache.erb @@ -9,7 +9,7 @@ WSGIDaemonProcess <%= @name %> user=<%= @user %> group=<%= @group %> processes=4 <% end -%> ServerAdmin webmaster@openstreetmap.org - CustomLog /var/log/apache2/<%= @name %>-access.log combined + CustomLog /var/log/apache2/<%= @name %>-access.log combined_extended ErrorLog /var/log/apache2/<%= @name %>-error.log RedirectPermanent /.well-known/acme-challenge/ http://acme.openstreetmap.org/.well-known/acme-challenge/ @@ -28,7 +28,7 @@ WSGIDaemonProcess <%= @name %> user=<%= @user %> group=<%= @group %> processes=4 SSLCertificateFile /etc/ssl/certs/<%= @name %>.pem SSLCertificateKeyFile /etc/ssl/private/<%= @name %>.key - CustomLog /var/log/apache2/<%= @name %>-access.log combined + CustomLog /var/log/apache2/<%= @name %>-access.log combined_extended ErrorLog /var/log/apache2/<%= @name %>-error.log RedirectPermanent / https://<%= @name %>/ @@ -43,7 +43,7 @@ WSGIDaemonProcess <%= @name %> user=<%= @user %> group=<%= @group %> processes=4 SSLCertificateFile /etc/ssl/certs/<%= @name %>.pem SSLCertificateKeyFile /etc/ssl/private/<%= @name %>.key - CustomLog /var/log/apache2/<%= @name %>-access.log combined + CustomLog /var/log/apache2/<%= @name %>-access.log combined_extended ErrorLog /var/log/apache2/<%= @name %>-error.log DocumentRoot <%= @directory %>/osqa @@ -53,6 +53,27 @@ WSGIDaemonProcess <%= @name %> user=<%= @user %> group=<%= @group %> processes=4 WSGIScriptAlias / <%= @directory %>/osqa/osqa.wsgi WSGIProcessGroup <%= @name %> + + # Site is now closed. Block access to login page and other pages. + + Require all denied + ErrorDocument 403 "help.openstreetmap.org is closed. Use community.openstreetmap.org instead." + + + Require all denied + ErrorDocument 403 "help.openstreetmap.org is closed. Use community.openstreetmap.org instead." + + + Require all denied + ErrorDocument 403 "help.openstreetmap.org is closed. Use community.openstreetmap.org instead." + + + Require all denied + ErrorDocument 403 "help.openstreetmap.org is closed. Use community.openstreetmap.org instead." + + RewriteEngine on + RewriteCond %{REQUEST_METHOD} POST + RewriteRule ^/questions - [F,NC] /osqa>