Docker Deployment
The standard deployment runs a backend and frontend on one Docker host with persistent bind mounts.
Prerequisites
- Docker Engine or Docker Desktop
- Docker Compose v2, invoked as
docker compose - Persistent storage sized for recordings
Installer
Linux and macOS:
curl -fsSL https://docs.srec.rs/install.sh | bashWindows PowerShell:
irm https://docs.srec.rs/install.ps1 | iexThe installer downloads Compose and environment files, generates unique secrets, detects optional NVIDIA support, and offers to start the services. Both entry points pick a localized installer from SREC_LANG or the system locale; set SREC_LANG explicitly to override it.
Review Remote Scripts
Piping a remote script to a shell executes the current network response. Environments with change control should download the script, verify its contents and checksum, then run the reviewed local copy or use the manual setup below.
Installer settings:
| Variable | Purpose | Default |
|---|---|---|
SREC_LANG | en or zh | Detected from locale |
RUST_SREC_DIR | Installation directory | ./rust-srec |
VERSION | Image tag | latest |
For a reviewed release, set an explicit version. Example for Linux/macOS:
curl -fsSL https://docs.srec.rs/install.sh | RUST_SREC_DIR=/opt/rust-srec VERSION=v0.5.1 bashManual Setup
Create a directory and download both files:
Rename them to
docker-compose.ymland.env.Generate two different secrets and set
JWT_SECRETandSESSION_SECRETin.env. Empty values intentionally make Compose refuse to start.Review paths, timezone, ports, and
VERSION.Start and verify:
docker compose up -d
docker compose ps
curl http://localhost:12555/api/health/liveGenerate a secret with openssl rand -hex 32. Where openssl is unavailable, use python3 -c 'import secrets; print(secrets.token_hex(32))'. On PowerShell:
$bytes = New-Object Byte[] 32
[Security.Cryptography.RandomNumberGenerator]::Create().GetBytes($bytes)
-join ($bytes | ForEach-Object { "{0:x2}" -f $_ })Default Layout
| Host | Container | Purpose |
|---|---|---|
./data | /app/data | SQLite and application data |
./config | /app/config | Platform configuration |
./output | /app/output | Recordings and pipeline output |
./logs | /app/logs | Application logs |
12555 | Backend 8080 | API and Swagger |
15275 | Frontend 80 | Web interface |
Use absolute host paths for a long-running deployment. The example enables unless-stopped, backend health checks, frontend startup ordering, and container log rotation.
Access and First Login
- Web interface:
http://localhost:15275 - Swagger UI:
http://localhost:12555/api/docs - Initial account:
admin/admin123!
The first login requires a password change. Continue with Make Your First Recording.
Optional Configuration
Proxy
Set HTTP_PROXY, HTTPS_PROXY, and NO_PROXY in .env; the example already passes them to the backend. Then enable Global Settings > Downloader > Proxy > Use System Proxy. Include localhost,127.0.0.1,rust-srec in NO_PROXY.
Browser Push
Generate VAPID keys, place them in .env, and restart the backend. Web Push requires HTTPS outside localhost. See Notification System.
NVIDIA GPU
Install the host driver and NVIDIA Container Toolkit, then download docker-compose.gpu.yml and start with:
docker compose -f docker-compose.yml -f docker-compose.gpu.yml up -d
docker exec rust-srec nvidia-smiGPU access only enables compatible processors; select an NVENC processor in the pipeline and monitor the GPU component on System Health.
Storage Cleanup
Delete files inside the mounted output directory; do not rename, replace, or move the host directory that is itself bind-mounted while the container is running. File managers that implement deletion by moving the root to trash can leave the active container attached to an orphaned directory.
If System Health reports output-root not_found, verify the host directory and restart the container to recreate the mount namespace. For storage_full, free capacity without replacing the directory; the gate can recover on a later probe. See Storage and Capacity and the FAQ.
Stop, Update, and Remove
# Stop while keeping data
docker compose stop
# Start again
docker compose up -dUse Upgrade and Rollback before changing VERSION. docker compose down removes containers and the network but leaves bind-mounted host data; verify exact paths before deleting any host directory.
For an Internet-facing host, complete Production Deployment instead of publishing the example ports directly.