Commit c9a6403
dstack-ingress 2.0: switch from nginx to haproxy for L4 TCP proxying
Replace nginx L7 reverse proxy with HAProxy in TCP mode. This eliminates
HTTP-level inspection so all protocols (HTTP, WebSocket, gRPC, arbitrary
TCP) work transparently after TLS termination.
Key changes:
- Dockerfile: nginx base -> haproxy:3.1-bookworm, master-worker mode
- entrypoint.sh: generate haproxy.cfg instead of nginx conf, support
ROUTING_MAP env var for multi-domain SNI-based routing
- renewal-daemon.sh: graceful reload via SIGUSR2 instead of nginx -s reload
- New build-combined-pems.sh: concat fullchain+privkey for HAProxy PEM format
- functions.sh: sanitize_target_endpoint accepts bare host:port
- Evidence serving: payload inspection on port 443 (default, opt-out via
EVIDENCE_SERVER=false) + shared /evidences volume for backend serving
- Configurable L4 tuning: MAXCONN, TIMEOUT_CONNECT/CLIENT/SERVER
- Drop L7-only env vars (CLIENT_MAX_BODY_SIZE, PROXY_*_TIMEOUT) with warnings
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent 9150c20 commit c9a6403
9 files changed
Lines changed: 311 additions & 361 deletions
File tree
- custom-domain/dstack-ingress
- scripts
- tests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
| 2 | + | |
| 3 | + | |
2 | 4 | | |
3 | 5 | | |
4 | 6 | | |
| |||
32 | 34 | | |
33 | 35 | | |
34 | 36 | | |
35 | | - | |
36 | | - | |
37 | | - | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
38 | 41 | | |
39 | 42 | | |
40 | 43 | | |
| |||
62 | 65 | | |
63 | 66 | | |
64 | 67 | | |
65 | | - | |
| 68 | + | |
0 commit comments