From b01179f08d990df3f4a41c87eaba740d5ade29b1 Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Thu, 11 Dec 2014 22:33:45 +0000 Subject: [PATCH] Add apache 2.4 support to the mediawiki cookbook --- .../mediawiki/templates/default/apache.erb | 46 +++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/cookbooks/mediawiki/templates/default/apache.erb b/cookbooks/mediawiki/templates/default/apache.erb index 40e206d1b..6cbbc76e6 100644 --- a/cookbooks/mediawiki/templates/default/apache.erb +++ b/cookbooks/mediawiki/templates/default/apache.erb @@ -48,6 +48,9 @@ > Options -Indexes +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all granted +<% end -%> /images/> @@ -78,13 +81,21 @@ /maintenance/> +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all denied +<% else -%> Order allow,deny Deny from all +<% end -%> /LocalSettings.php> +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all denied +<% else -%> Order allow,deny Deny from all +<% end -%> /images/> @@ -102,18 +113,30 @@ +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all denied +<% else -%> Order allow,deny Deny from all +<% end -%> +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all denied +<% else -%> Order allow,deny Deny from all +<% end -%> +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all denied +<% else -%> Order allow,deny Deny from all +<% end -%> <% if @mediawiki[:enable_ssl] -%> @@ -167,6 +190,9 @@ > Options -Indexes +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all granted +<% end -%> /images/> @@ -189,13 +215,21 @@ /maintenance/> +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all denied +<% else -%> Order allow,deny Deny from all +<% end -%> /LocalSettings.php> +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all denied +<% else -%> Order allow,deny Deny from all +<% end -%> /images/> @@ -213,18 +247,30 @@ +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all denied +<% else -%> Order allow,deny Deny from all +<% end -%> +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all denied +<% else -%> Order allow,deny Deny from all +<% end -%> +<% if node[:lsb][:release].to_f >= 14.04 -%> + Require all denied +<% else -%> Order allow,deny Deny from all +<% end -%> <% end -%> -- 2.39.5