Wednesday, 15 May 2013

Is it possible to configure an nginx location to serve a root folder based date of creation? -



Is it possible to configure an nginx location to serve a root folder based date of creation? -

i have set of static files automatically deployed configured nginx root location.

each build generates versioned set of resources (static html/css/javascript) per below:

location ~ ^/(mylocation) { root /local/0/www/; autoindex on; auth_request off; expires 5d; add_header access-control-allow-origin *; proxy_cache static_one; proxy_cache_valid 200 60m; proxy_cache_valid 404 1m; proxy_cache_use_stale error timeout invalid_header updating http_500 http_502 http_503 http_504; }

inside "mylocation" directory number of versioned directories 1.0, 1.0.1, 1.0.2 etc.

is feasible have nginx serve recent (highest version number) default whilst still enabling serve individual versions directly?

nginx

No comments:

Post a Comment