From 634162e0d99aa1f02397b870f0a9a2b1617c7ebc Mon Sep 17 00:00:00 2001 From: wangjia <809946525@qq.com> Date: Sun, 24 May 2026 20:28:48 +0800 Subject: [PATCH] =?UTF-8?q?fix(nginx):=20index.html=20=E7=A6=81=E7=94=A8?= =?UTF-8?q?=E7=BC=93=E5=AD=98=EF=BC=8C=E7=A1=AE=E4=BF=9D=E5=8F=91=E7=89=88?= =?UTF-8?q?=E5=90=8E=E7=AB=8B=E5=8D=B3=E7=94=9F=E6=95=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 4.6 --- deploy/nginx-jiu.conf | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/deploy/nginx-jiu.conf b/deploy/nginx-jiu.conf index 01677f9..3ec4f6c 100644 --- a/deploy/nginx-jiu.conf +++ b/deploy/nginx-jiu.conf @@ -39,6 +39,14 @@ server { try_files $uri $uri/ /app/index.html; } + # index.html 不缓存,确保每次发版后浏览器加载最新版 + location = /app/index.html { + alias /opt/jiu/web/index.html; + add_header Cache-Control "no-cache, no-store, must-revalidate"; + add_header Pragma "no-cache"; + expires 0; + } + # 扫码页(/scan/ → scan.html,JS 从 URL 读取 id) location /scan/ { root /opt/jiu/marketing;