X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/82224d67c988af7e0934a1e354dd3c083e55a832..f5296ebe7c9608620d72fe3936706a0408a30c5b:/cookbooks/mediawiki/templates/default/apache.erb diff --git a/cookbooks/mediawiki/templates/default/apache.erb b/cookbooks/mediawiki/templates/default/apache.erb index 7aed4b3e7..a3cb02ad1 100644 --- a/cookbooks/mediawiki/templates/default/apache.erb +++ b/cookbooks/mediawiki/templates/default/apache.erb @@ -21,6 +21,10 @@ DocumentRoot <%= @directory %> +<% if @ssl_enabled -%> + RedirectPermanent /.well-known/acme-challenge/ http://acme.openstreetmap.org/.well-known/acme-challenge/ +<% end -%> + php_admin_value open_basedir <%= @directory %>/:/usr/share/php/:/tmp/ #php_admin_value disable_functions "exec,shell_exec,system,passthru,popen,proc_open" php_value memory_limit 128M @@ -57,6 +61,7 @@ RewriteCond %{REQUEST_URI} !^/api\.php$ RewriteCond %{REQUEST_URI} !^/opensearch_desc\.php$ RewriteCond %{REQUEST_URI} !^/server-status + RewriteCond %{REQUEST_URI} !^/.well-known/ RewriteCond %{LA-U:REQUEST_FILENAME} !-f RewriteCond %{LA-U:REQUEST_FILENAME} !-d RewriteRule ^/(.*) /wiki/$1 [R,L]