Reproduction steps
- Self-host Fluxer behind the Cloudflare proxy (orange cloud, not a Tunnel). Gateway on the default wss://<instance>/gateway.
- Keep a client connected for a few hours, or hold a few gateway connections open with a script that logs every drop and the CF-RAY colo.
- In the same window, hold a connection that goes straight to the origin (a DNS-only hostname pointed at the same server).
- Compare the two. The Cloudflare connections drop in bursts; the direct one doesn't.
Expected behaviour
The gateway connection stays up, like it does when it skips Cloudflare.
Actual behaviour
Members get random "reconnecting" banners, and voice sometimes resumes mid-call (LiveKit signaling goes through the same proxy).
My probe logged over 1,000 Cloudflare drops in about two days, in bursts: sometimes every couple of minutes for hours, mostly in the afternoon and evening (US time). The direct connection dropped 0 times outside of server restarts, through the same Traefik and Caddy.
Drops are silent: no close frame, the client only notices on its next heartbeat. I ran the probe from home and from the server itself, and both dropped at the same moments, so it's not anyone's ISP. During bursts the reconnects land on Cloudflare colos all over the world (Paris, Tokyo, Sao Paulo...), not just the nearby ones.
My guess is that Cloudflare moves long-lived connections around under load. I can't prove that from my side.
Platform
Self-hosting
Evidence
Instance version: 2026.1118.162713 (rexctl). Setup: Cloudflare proxy → Traefik → Caddy edge.
What fixed it: a second, DNS-only hostname just for realtime traffic.
- FLUXER_GATEWAY_ENDPOINT=wss://rt.<instance host>/gateway
- FLUXER_LIVEKIT_URL=https://rt.<instance host>/livekit
- FLUXER_CSP_EXTRA_CONNECT_SRC with both https:// and wss:// for that host
- The voice server endpoint in the admin panel. FLUXER_LIVEKIT_URL didn't update it, because my voice server isn't in the default region.
- The Android app only accepts a gateway host that equals the instance host or is a subdomain of it. Anything else fails login with "Couldn't read the instance's configuration" (isGatewayTrustedForApi).
- Existing desktop clients keep the old gateway until they sign out and back in (filing that separately).
Comments
No comments yet.