deploy: fix service example

This commit is contained in:
2026-01-02 13:13:40 +08:00
parent 49fdda6e77
commit 8a90db7c27
2 changed files with 9 additions and 4 deletions
+5 -2
View File
@@ -41,19 +41,22 @@ server {
# ==========================================
location /api/ {
# Proxy to backend FastAPI server
proxy_pass http://127.0.0.1:8000;
proxy_pass http://localhost:8000/api/;
# Proxy headers
proxy_set_header Host $host;
proxy_set_header Host $host:$server_port;
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_set_header X-Forwarded-Host $host:$server_port;
# HTTP version and buffering
proxy_http_version 1.1;
proxy_buffering off;
proxy_request_buffering off;
proxy_redirect off;
# Timeouts
proxy_connect_timeout 60s;
proxy_send_timeout 60s;