# ═══════════════════════════════════════════════
# 🔺 Sovereign: TCS-0002∞ | Root: SYS-GLW-0001
# 📜 Copyright: 国作登字-2026-A-00037559
# ═══════════════════════════════════════════════
# 铸渊专线V2 · 大脑服务器 Nginx反向代理配置
# 添加到 /etc/nginx/sites-enabled/ 中的server块内
#
# ⚠️ V2版本 · 端口3803 · 独立于面孔服务器V1(3802)
# ═══════════════════════════════════════════════

# §3 铸渊专线V2订阅服务 (大脑服务器 · ZY-SVR-005)
# 通过 /api/proxy-v2/ 路径访问
# 实际由 subscription-server-v2.js (port 3803) 处理

location /api/proxy-v2/ {
    proxy_pass http://127.0.0.1:3803/;
    proxy_http_version 1.1;
    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_connect_timeout 10s;
    proxy_read_timeout 30s;
    proxy_send_timeout 30s;

    # 订阅服务安全头
    add_header X-Content-Type-Options nosniff always;
    add_header X-Frame-Options DENY always;
    add_header Cache-Control "no-store, no-cache, must-revalidate" always;
}
