# Get the real remote IP for requests via a trusted proxy
RemoteIPHeader X-Forwarded-For
<% @caches.each do |cache| -%>
-<% cache.ipaddresses(:role => :external) do |address| -%>
+<% cache.ipaddresses(:role => :external).sort.each do |address| -%>
RemoteIPTrustedProxy <%= address %>
<% end -%>
<% end -%>
# Rewrite tile requests to the default style
RewriteRule ^/(-?\d+)/(-?\d+)/(-?\d+)\.png$ /default/$1/$2/$3.png [PT,T=image/png,L]
+ RewriteRule ^/(-?\d+)/(-?\d+)/(-?\d+)\.png/status/?$ /default/$1/$2/$3.png/status [PT,T=text/plain,L]
+ RewriteRule ^/(-?\d+)/(-?\d+)/(-?\d+)\.png/dirty/?$ /default/$1/$2/$3.png/dirty [PT,T=text/plain,L]
</VirtualHost>
<Directory /srv/tile.openstreetmap.org/html>