From: Sarah Hoffmann Date: Tue, 14 Oct 2014 18:14:49 +0000 (+0200) Subject: match complete URIs in nominatim's apache conf X-Git-Url: https://git.openstreetmap.org/chef.git/commitdiff_plain/dda736cb32c650afe6d18c1fa311c4b68c1e0fde?ds=sidebyside match complete URIs in nominatim's apache conf --- diff --git a/cookbooks/nominatim/templates/default/apache.erb b/cookbooks/nominatim/templates/default/apache.erb index 4c16dcf4f..be0e48a59 100644 --- a/cookbooks/nominatim/templates/default/apache.erb +++ b/cookbooks/nominatim/templates/default/apache.erb @@ -31,9 +31,9 @@ <% if node[:lsb][:release].to_f >= 14.04 -%> - ProxyPassMatch /((?!pool-.*).*\.php(/.*)?)$ fcgi://127.0.0.1:<%= @pools[:www][:port ]%><%= @directory %>/website/$1 + ProxyPassMatch ^/([^/]*\.php(/.*)?)$ fcgi://127.0.0.1:<%= @pools[:www][:port ]%><%= @directory %>/website/$1 <% else -%> - + SetHandler fcgi:/var/run/php5-fpm-www.sock <% end -%> @@ -41,9 +41,9 @@ <% @pools.each do |name,details| -%> Alias /pool-<%= name %>/ "<%= @directory %>/website/" <% if node[:lsb][:release].to_f >= 14.04 -%> - ProxyPassMatch /pool-<%= name %>/(.*\.php(/.*)?) fcgi://127.0.0.1:<%= details[:port ]%><%= @directory %>/website/$1 + ProxyPassMatch ^/pool-<%= name %>/(.*\.php(/.*)?) fcgi://127.0.0.1:<%= details[:port ]%><%= @directory %>/website/$1 <% else -%> - /(.*\.php(/.*)?)$> + /(.*\.php(/.*)?)$> SetHandler fcgi:/var/run/php5-fpm-<%= name %>.sock <% end -%>