]> git.openstreetmap.org Git - chef.git/commitdiff
Only allow access to export from known caches
authorTom Hughes <tom@compton.nu>
Wed, 30 Nov 2016 08:47:49 +0000 (08:47 +0000)
committerTom Hughes <tom@compton.nu>
Wed, 30 Nov 2016 09:09:02 +0000 (09:09 +0000)
cookbooks/tile/templates/default/apache.erb

index c41c923bf225a3eac464f426dc81c2f773df8212..fbc781c90bf86714a39c2593f7ab496c09e16803 100644 (file)
   AllowOverride None
   Require all granted
 </Directory>
+
+<Location /cgi-bin/export>
+<% @caches.each do |cache| -%>
+<% cache.ipaddresses(:role => :external).sort.each do |address| -%>
+  Require ip <%= address %>
+<% end -%>
+<% end -%>
+</Location>