Stop no-store headers getting through for the proxy

This commit is contained in:
Andrew Godwin 2022-12-26 20:53:50 -07:00
parent 201b410383
commit 218aabc597
2 changed files with 3 additions and 0 deletions

View file

@ -99,6 +99,8 @@ http {
proxy_cache_valid 301 307 12h;
proxy_cache_valid 500 502 503 504 0s;
proxy_cache_valid any 72h;
proxy_hide_header Cache-Control;
add_header Cache-Control "public, max-age=3600";
add_header X-Cache $upstream_cache_status;
}

View file

@ -31,6 +31,7 @@ class BaseProxyView(View):
headers={
"X-Accel-Redirect": "/__takahe_accel__/",
"X-Takahe-RealUri": remote_url,
"Cache-Control": "public, max-age=3600",
},
)
else: