]> git.openstreetmap.org Git - rails.git/commitdiff
Strip asset tags from public files.
authorTom Hughes <tom@compton.nu>
Mon, 20 Apr 2009 17:09:26 +0000 (17:09 +0000)
committerTom Hughes <tom@compton.nu>
Mon, 20 Apr 2009 17:09:26 +0000 (17:09 +0000)
config/nginx.conf

index b9055c2d38bb951717ce880e5ef1b1f2c53f5441..bd43f4c35bad85dfc5649b6c02a10962c2958234 100644 (file)
@@ -148,6 +148,11 @@ http {
             rewrite ^/(0\.[0-9]+)/(.*)$ /api/$1/$2;
         }
     
+        # Strip asset tags
+        location ~ ^/(images|javascripts|openlayers|stylesheets)/ {
+            rewrite ^/(.*)/[0-9]+$ /$1;
+        }
+
         # Handle tiles@home requests
         location /api/ {
             if ($http_user_agent ~ "^tilesAtHome") {