fix: no cache

This commit is contained in:
Niklas 2023-03-14 20:30:32 +01:00
parent da0f3b1e46
commit 212606febd
2 changed files with 12 additions and 10 deletions

View File

@ -28,14 +28,18 @@ server {
location /nginx {
return 404;
return 403;
}
location ~ thumbnail {
location /translation {
return 403;
}
location ~* (.*/thumbnail)/(.+\.png)$ {
# kill cache
add_header Cache-Control 'no-store, no-cache';
expires off;
expires -1;
etag off;
add_header 'Cache-Control' 'no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0';
include conf.d/corsdefault.template;
}
@ -50,9 +54,9 @@ server {
location ~*\.(json)$ {
# kill cache
add_header Cache-Control 'no-store, no-cache';
expires off;
expires -1;
etag off;
add_header 'Cache-Control' 'no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0';
include conf.d/corsdefault.template;
}

View File

@ -5,11 +5,9 @@ server {
location / {
# kill cache
add_header Last-Modified $date_gmt;
add_header Cache-Control 'no-store, no-cache';
if_modified_since off;
expires off;
expires -1;
etag off;
add_header 'Cache-Control' 'no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0';
root /usr/share/nginx/html;
index index.html index.htm;