Commit ab8422e3 by zhangxingmin

push

parent ac965f5d
...@@ -2,13 +2,10 @@ server { ...@@ -2,13 +2,10 @@ server {
listen 6688; listen 6688;
server_name 139.224.145.34; server_name 139.224.145.34;
# 为 .mjs 文件设置正确的 MIME 类型(解决 PDF.js worker 加载失败)
location ~ \.mjs$ { location ~ \.mjs$ {
root /usr/share/nginx/html; root /usr/share/nginx/html;
add_header Content-Type application/javascript; default_type application/javascript; # 设置默认 MIME 类型
# 如果需要支持跨域(可选,与你的其他配置保持一致)
add_header 'Access-Control-Allow-Origin' '*'; add_header 'Access-Control-Allow-Origin' '*';
# 缓存控制(可选)
expires 1y; expires 1y;
add_header Cache-Control "public, immutable"; add_header Cache-Control "public, immutable";
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment