From: Grant Slater Date: Sun, 8 Dec 2019 18:52:13 +0000 (+0000) Subject: tilecache: use conditional validation upstream X-Git-Url: https://git.openstreetmap.org/chef.git/commitdiff_plain/0f1dd9c9525203c7c4fe682f4ce99942344e193b tilecache: use conditional validation upstream --- diff --git a/cookbooks/tilecache/templates/default/nginx_tile.conf.erb b/cookbooks/tilecache/templates/default/nginx_tile.conf.erb index 07bf8fcd9..6895ea54c 100644 --- a/cookbooks/tilecache/templates/default/nginx_tile.conf.erb +++ b/cookbooks/tilecache/templates/default/nginx_tile.conf.erb @@ -225,9 +225,11 @@ server { proxy_cache_use_stale error timeout updating http_500 http_503 http_504; # If in cache as stale, serve stale and update in background proxy_cache_background_update on; + # Enable revalidation using If-Modified-Since and If-None-Match for stale items + proxy_cache_revalidate on; proxy_cache_min_uses 8; - add_header X-Nginx-Cache-Status $upstream_cache_status; + add_header x-cache-status $upstream_cache_status; <% end -%> # Set a QoS cookie if none presented (uses nginx Map)