From 1b79bf8457c82f86d2f921dfd67b41d2cb5e2a8f Mon Sep 17 00:00:00 2001 From: Quan Tran Date: Fri, 12 May 2023 16:29:09 +0700 Subject: [PATCH] Force browsers to re-validate cache before reuse Upon new release, NGINX would return 200 OK with new static files. Otherwise, NGINX would return 304 Not Modified with empty response, and browser continue to reuse cached static files. (cherry picked from commit 4506a5e4901299dfcb8ba2524e2a6c451fffcf90) --- server/nginx.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/nginx.conf b/server/nginx.conf index 08492dc8e..913bee30d 100644 --- a/server/nginx.conf +++ b/server/nginx.conf @@ -22,7 +22,7 @@ http { #tcp_nopush on; keepalive_timeout 65; - expires 86400; + add_header Cache-Control "no-cache"; etag on; include /etc/nginx/conf.d/*.conf;