compose: decouple livekit from default stack — behind live profile#912
compose: decouple livekit from default stack — behind live profile#912
Conversation
Text chat (Carl's first experience) doesn't need LiveKit. Voice/video is opt-in via `docker compose --profile live up`. Changes: - livekit + livekit-bridge: profiles: [live] (was always-on) - continuum-core: removed depends_on livekit-bridge (was blocking startup even when livekit-bridge wasn't needed for text chat) Savings for default `docker compose up`: - ~300MB RAM (livekit-server + livekit-bridge) - 3 ports freed (7880 WS, 7881 TCP, 7882 UDP) - Faster startup (no livekit healthcheck wait) - Fewer port collisions with native dev tools (7882/UDP was the collision that blocked FlashGordon M1 cell test earlier) livekit-grid stays in `grid` profile (unchanged). docker compose config validates clean for default, --profile live, --profile grid, and Mac overlay.
There was a problem hiding this comment.
Pull request overview
This PR makes the default docker compose up stack smaller by gating LiveKit (and the Rust livekit-bridge) behind a live compose profile, so text chat works without pulling in WebRTC services.
Changes:
- Removed
continuum-core’s startup dependency onlivekit-bridge. - Moved
livekit-bridgebehindprofiles: [live]. - Moved
livekitbehindprofiles: [live]and updated inline guidance/comments accordingly.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| # Core starts independently; connections to optional services (postgres | ||
| # pool, livekit bridge socket) retry on demand. Text chat works without | ||
| # any profile active — voice/video requires `--profile live`. |
There was a problem hiding this comment.
The comment says optional service connections (including the livekit-bridge socket) “retry on demand”, but continuum-core’s bridge client currently does a single UnixStream::connect() attempt and returns an error if the socket isn’t present; voice_register_session just logs that error and doesn’t retry. With --profile live, this can create a startup race where the first voice session fails if triggered before livekit-bridge finishes booting. Consider either (a) adjusting this comment to reflect the actual behavior (best-effort connect, may fail until bridge is up), or (b) adding a small retry/backoff around the initial bridge socket connect so voice can succeed immediately after stack startup.
| # Core starts independently; connections to optional services (postgres | |
| # pool, livekit bridge socket) retry on demand. Text chat works without | |
| # any profile active — voice/video requires `--profile live`. | |
| # Core starts independently; connections to optional services are | |
| # best-effort at startup and may fail until those services are ready | |
| # (for example, the livekit bridge socket when using `--profile live`). | |
| # Text chat works without any profile active — voice/video requires | |
| # `--profile live`. |
Browser can't resolve 'ws://livekit:7880' — that's Docker-internal DNS, only works from inside containers. The browser runs on the host where 'livekit' is not a valid hostname. localhost:7880 works because the livekit container binds port 7880 to the host. Grid mode unaffected — explicitly sets LIVEKIT_BROWSER_URL=ws://tailscale:7880. Fixes the 14-persona-3D-call from the README headline — collaboration/live/join now returns a browser-reachable LiveKit URL.
Summary
livecompose profile--profile liveWhy
Carl's first chat doesn't need WebRTC. Default stack should be minimal:
continuum-core + node-server + widget-server + model-init. Voice/video
is a feature discovery, not a prerequisite.
Saves ~300MB RAM + 3 ports + faster startup on default
docker compose up.Also eliminates the port 7882/UDP collision that blocked FlashGordon M1
cell testing during PR891.
Test plan
docker compose config --servicesshows no livekit in defaultdocker compose --profile live config --servicesincludes both-f docker-compose.mac.yml) validates clean--profile live(BigMama verified in PR891)🤖 Generated with Claude Code