add example in docker-compose, clarify README, add clearer validation, longer timeouts for websocket connections

This commit is contained in:
Zimeng Xiong
2025-12-01 13:27:31 -08:00
parent f9986513f8
commit f8830a8b0f
4 changed files with 25 additions and 10 deletions
+7 -3
View File
@@ -27,7 +27,7 @@ http {
proxy_pass http://${BACKEND_URL}/;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
proxy_set_header X-Real-IP $remote_addr;
@@ -52,12 +52,16 @@ http {
proxy_pass http://${BACKEND_URL}/socket.io/;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
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;
# Longer timeouts for WebSocket connections
proxy_read_timeout 3600s;
proxy_send_timeout 3600s;
}
# Frontend routes
@@ -71,4 +75,4 @@ http {
add_header Cache-Control "public, immutable";
}
}
}
}