diff --git a/recipes/apache2.rb b/recipes/apache2.rb index d9e8836..043419c 100644 --- a/recipes/apache2.rb +++ b/recipes/apache2.rb @@ -6,4 +6,9 @@ include_recipe 'apache2::mod_proxy_http' include_recipe 'apache2::mod_ssl' +# Disable mod_auth_basic because it isn't supported in Stash 2.10 and later +apache_module "auth_basic" do + enable false +end + web_app node['stash']['apache2']['virtual_host_name'] diff --git a/templates/default/web_app.conf.erb b/templates/default/web_app.conf.erb index fb3d947..cc28e81 100644 --- a/templates/default/web_app.conf.erb +++ b/templates/default/web_app.conf.erb @@ -13,14 +13,11 @@ <% end -%> <% end -%> DocumentRoot <%= node['stash']['install_path'] %> - + CustomLog <%= node['stash']['apache2']['access_log'].empty? ? node['apache']['log_dir']+"/stash-access.log" : node['stash']['apache2']['access_log'] %> combined ErrorLog <%= node['stash']['apache2']['error_log'].empty? ? node['apache']['log_dir']+"/stash-error.log" : node['stash']['apache2']['error_log'] %> LogLevel warn - # Make sure we disable/prevent basic authentication attempts since Stash 2.1+ can't handle them - RequestHeader unset Authorization - <% if node['apache'] && node['apache']['version'] == '2.4' %> Require all granted @@ -49,9 +46,6 @@ ErrorLog <%= node['stash']['apache2']['ssl']['error_log'].empty? ? node['apache']['log_dir']+"/stash-ssl-error.log" : node['stash']['apache2']['ssl']['error_log'] %> LogLevel warn - # Make sure we disable/prevent basic authentication attempts since Stash 2.1+ can't handle them - RequestHeader unset Authorization - <% if node['apache'] && node['apache']['version'] == '2.4' %> Require all granted