Files
2026-03-01 10:27:12 -05:00

34 lines
1.0 KiB
Plaintext

server {
listen 80;
server_name _;
root /usr/share/nginx/html;
index index.html;
etag on;
# The Godot web export uses stable filenames (index.js, index.wasm, index.pck).
# Force the browser to revalidate on each navigation so a new deployment is
# picked up without manually clearing the cache.
location = /index.html {
add_header Cache-Control "no-store, no-cache, must-revalidate" always;
add_header Pragma "no-cache" always;
add_header Expires "0" always;
try_files $uri =404;
}
location ~* \.(js|wasm|pck|png|jpg|jpeg|gif|svg|webp|json|txt|import)$ {
add_header Cache-Control "no-cache, max-age=0, must-revalidate" always;
add_header Pragma "no-cache" always;
add_header Expires "0" always;
try_files $uri =404;
}
location / {
add_header Cache-Control "no-cache, max-age=0, must-revalidate" always;
add_header Pragma "no-cache" always;
add_header Expires "0" always;
try_files $uri $uri/ /index.html;
}
}