Skip to content

Docker Compose Deployment

The repository provides two Compose files:

FilePurposeBehavior
docker-compose.dev.ymlLocal developmentBuilds from the local Dockerfile and includes development secrets
docker-compose.ymlImage-based deploymentUses zijiren/synctv:latest and requires explicit production secrets

Start:

Terminal window
docker compose -f docker-compose.dev.yml up -d

This starts:

  • PostgreSQL 18.
  • Redis 8.
  • SyncTV built from the local Dockerfile.

It includes development-only JWT, cluster, credential encryption, OPAQUE, and root password values.

Compose uses volumes for:

  • PostgreSQL data.
  • Redis data.
  • SyncTV /data runtime directory.

/data corresponds to:

Terminal window
SYNCTV_DATA_DIR=/data

This directory may contain:

  • Management socket runtime files.
  • HLS files.
  • Proxy slice cache files.
  • Other runtime-owned outputs.

Default exposed ports:

Host portContainer portPurpose
80808080HTTP REST + gRPC + health checks
19351935RTMP
3478/udp3478/udpSTUN

If a host port conflicts, edit the Compose port mapping.

Compose checks:

http://localhost:8080/health/ready

If health checks fail, inspect logs:

Terminal window
docker compose logs -f synctv

Why does production Compose require secrets?

Section titled “Why does production Compose require secrets?”

Because weak automatic defaults are unsafe. The service should not accidentally start in production with known secrets.

Users cannot log in after changing SYNCTV_SECURITY_OPAQUE_SERVER_SETUP_SECRET

Section titled “Users cannot log in after changing SYNCTV_SECURITY_OPAQUE_SERVER_SETUP_SECRET”

That secret must remain stable. Changing it can make existing OPAQUE password records unverifiable.

At minimum:

  • PostgreSQL volume.
  • Production secrets.

Depending on enabled features:

  • /data HLS files.
  • Proxy slice cache.

Redis is usually short-lived shared state, but losing it can affect OAuth2 state, token blacklist, and rate-limit counters.