This commit is contained in:
vet
2026-04-20 17:26:25 +07:00
parent fa6b610ddf
commit 83d425b182
8 changed files with 27 additions and 87 deletions

View File

@@ -30,9 +30,6 @@ server {
listen [::]:80;
server_name cms-jack.imharry.work;
root /app/pc/dist;
index index.html;
client_max_body_size 100m;
add_header Cross-Origin-Opener-Policy "same-origin" always;
add_header Cross-Origin-Embedder-Policy "credentialless" always;
@@ -113,8 +110,19 @@ server {
return 200 "ok\n";
}
# PC 静态构建产物。
# PC Vite dev:web server.
location / {
try_files $uri $uri/ /index.html;
proxy_pass http://127.0.0.1:5173;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_cache_bypass $http_upgrade;
proxy_buffering off;
proxy_read_timeout 86400s;
proxy_send_timeout 86400s;
}
}