Skip to content

Infrastructure

WebSocket and longpolling

Live notifications and chat in the ERP use WebSocket. Soviez routes it for you.

Standard layout

When automatic sizing runs several workers (workers > 0):

proxy_mode = True
list_db = False
workers = <calculated>
gevent_port = 8072

Client :443 / WSS
 → Nginx
   /            → 127.0.0.1:<HOST_PORT>    → container 8069 (HTTP workers)
   /websocket   → 127.0.0.1:<GEVENT_PORT>  → container 8072 (evented)
   /longpolling → 127.0.0.1:<GEVENT_PORT>  → container 8072 (compatibility)

On very small servers sizing may pick a single-process setup (workers = 0), with WebSocket served by the HTTP backend.

Soviez sizes these settings from your server's resources; the numbers are not a service commitment.

Longpolling

Kept for compatibility, and routed to the evented backend when several workers run.

Production and Stage

Both run with proxy_mode = True behind Nginx.

Nginx

The Nginx sites Soviez manages include /websocket, /longpolling and the Upgrade headers, using map $http_upgrade $connection_upgrade on the server.

Ports

PortExposure
443Public (secure WebSocket)
8069Loopback only (HTTP)
8072Loopback only (evented / WebSocket)
8071Not public
5432Never public

Troubleshooting

SymptomCauseSafe action
404 on /websocketOld Nginx siteHave Soviez rebuild the site; don't open 8069/8072
400/426Missing Upgrade mapMake sure soviez_limits.conf is in place
502/504Wrong loopback portCheck the loopback ports for 8069 and 8072
Notifications don't arriveSeveral workers without gevent_portRun soviez.sh --tune

Never expose 8069 or 8072 publicly.