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
+8 -4
View File
@@ -114,19 +114,23 @@ docker compose up -d
# Access the frontend at localhost:6767
```
### Reverse proxy / Traefik setups
### Reverse Proxy / Traefik Setups (Docker)
When ExcaliDash runs behind Traefik, Nginx, or another reverse proxy, configure both containers so that API + WebSocket calls resolve correctly:
When running ExcaliDash behind Traefik, Nginx, or another reverse proxy, configure both containers so that API + WebSocket calls resolve correctly:
- `FRONTEND_URL` (backend) must match the public URL that users hit (e.g. `https://excalidraw.example.com`). This controls CORS and Socket.IO origin checks.
- `FRONTEND_URL` (backend) must match the public URL that users hit (e.g. `https://excalidash.example.com`). This controls CORS and Socket.IO origin checks.
- `BACKEND_URL` (frontend) tells the Nginx container how to reach the backend from inside Docker/Kubernetes. Override it if your reverse proxy exposes the backend under a different hostname.
```yaml
# docker-compose.yml example
backend:
environment:
- FRONTEND_URL=https://excalidraw.example.com
- FRONTEND_URL=https://excalidash.example.com
frontend:
environment:
# For standard Docker Compose (default)
# - BACKEND_URL=backend:8000
# For Kubernetes, use the service DNS name:
- BACKEND_URL=excalidash-backend.default.svc.cluster.local:8000
```