only use $uri as cache key

This commit is contained in:
hzrd149 2024-09-26 08:59:09 -05:00
parent 48ae3882a3
commit a367dee259

View File

@ -7,7 +7,7 @@ server {
proxy_cache request_cache;
proxy_cache_valid 200 60m;
proxy_cache_valid 404 10m;
proxy_cache_key $scheme$host$request_uri;
proxy_cache_key $uri;
proxy_cache_use_stale error timeout updating http_500 http_502 http_503 http_504;
add_header X-Cache $upstream_cache_status;
@ -16,8 +16,8 @@ server {
expires 30d;
add_header Cache-Control "public, no-transform";
proxy_set_header Host $host;
proxy_pass http://nsite;
proxy_set_header Host $host;
}
# Manual cache invalidation ( cant use proxy_cache_purge )