Files
koc-loop/deploy/nginx/koc-loop.conf
2026-08-15 03:53:09 +08:00

43 lines
1.2 KiB
Plaintext

server {
listen 80;
server_name _;
# 批量回填 Excel 会内嵌多篇笔记原图和截图。
client_max_body_size 85m;
location = /koc {
return 301 /koc/$is_args$args;
}
location /koc/ {
alias /usr/share/nginx/html/koc/;
try_files $uri $uri/ /koc/index.html;
add_header X-Robots-Tag "noindex, nofollow, noarchive" always;
add_header Referrer-Policy "no-referrer" always;
}
location /api/mcp {
proxy_pass http://app:3000;
proxy_http_version 1.1;
proxy_buffering off;
proxy_read_timeout 3600s;
proxy_send_timeout 3600s;
proxy_set_header Host $http_host;
proxy_set_header X-Forwarded-Host $http_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;
}
location / {
proxy_pass http://app:3000;
proxy_http_version 1.1;
proxy_set_header Host $http_host;
proxy_set_header X-Forwarded-Host $http_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_read_timeout 180s;
}
}