Requirements and sizing
The server, disk, memory and DNS names ClipMux needs, and how to size them for your library.
ClipMux runs on one Linux server with Docker. This page lists what that server needs before you install, what the installer checks for you, and how to size the disk and memory for the videos you expect.
The server
| Need | Why |
|---|---|
| Linux on amd64 or arm64 | The images are built for those two architectures. The installer refuses any other. |
Docker with the Compose v2 plugin (docker compose) | The stack is a Compose project. Run the installer as root, or as a user in the docker group. |
| Ports 80 and 443 free | The bundled Caddy serves HTTP and HTTPS on them, and gets a certificate for each of your hostnames. If another proxy already owns them, see Behind your own reverse proxy. |
| A kernel with Landlock (5.13 or later, enabled in the kernel's LSM list) | The built-in encoder confines ffmpeg with Landlock and seccomp. Without Landlock it doesn't start, and uploads wait in processing until another encoder takes them. |
Most current distributions' kernels have Landlock on. If yours doesn't, you can still run ClipMux and encode on Modal, RunPod or a PC you own.
Two DNS names
Point two hostnames at the server before you finish setup, for example:
video.example.com, the public URL: the dashboard, the API, and where browsers send uploads when videos are stored on this server.media.example.com, the media URL: where viewers' players fetch video.
Put the media hostname on a different registrable domain from the public
URL if you can (example-media.com rather than media.example.com), so a
hostile stored file can never reach the dashboard's cookies. You can leave
the media URL blank to serve playback from the public URL, but that is for
trying ClipMux out, not for production.
If you'll encode on Modal or RunPod, the public URL must be reachable from the internet: their machines call your server for each job.
What the installer checks
Before it downloads anything, the installer checks:
- that
docker composeworks and Docker answers; - the machine's architecture;
- free disk space, in the install directory and in Docker's own directory
(usually
/var/lib/docker): it stops below 4 GiB, and warns below 20 GiB; - on a first install, that ports 80 and 443 (or the ports you chose) are
free, when
ssis there to ask.
Disk
Everything ClipMux keeps on the server lives in Docker volumes: Postgres, and the data volume, which holds videos stored on this server and the encoder's scratch space. Plan for three things:
- The originals. ClipMux keeps every upload as it arrived, so it can encode it again.
- The encoded files. The renditions' video bitrates add up to about 10.3 Mbit/s for a 1080p source and 38 Mbit/s for a 4K one, and real files come in under that. Measured on lectures: 67 minutes of 1080p made 5.2 GB of encoded files, and 54 minutes of 4K made 5.9 GB.
- Room to encode. An encode needs about three times the source's size free in the encoder's scratch space while it runs.
If you store videos in a bucket instead, only the scratch space stays on the server. See Where videos are stored.
CPU or GPU
The built-in encoder uses the server's GPU when Docker gives the container
one: NVIDIA through NVENC, AMD and Intel through VAAPI. Otherwise it encodes
on the CPU with libx264. Encoding runs at idle priority, so the API and
playback stay responsive while it works, but a CPU encode of a long or 4K
video takes a long time. Each media tool is limited to 8 GiB of memory by
default (CLIPMUX_TOOL_MEMORY_MB).
A small VPS can hand encoding to a cloud GPU or a PC instead. See Encode on this server for passing a GPU into the container, and Encoding performance for measured times.
Memory for subtitles
Subtitles come from whisper.cpp, which runs inside the encoder. Its model
(large-v3-turbo, quantised) is about 0.9 GB and is already in the image, so
nothing is downloaded. With CLIPMUX_SPEECH left at auto, the encoder
transcribes on a GPU when one passes its test, and otherwise on the CPU only
when the machine has at least 4 cores and 6 GiB of memory. On a smaller
server, subtitles need a
speech API or another
encoder.
One server process
ClipMux supports one serve process. Rate limits, sign-in limits, the setup
token and several caches live in that process's memory, so a second replica
behind a load balancer would not share them. To grow, move work off the
server: storage to a bucket, encoding to a cloud GPU, playback to
Cloudflare.
Control-plane capacity
The capacity test ramps from 10 to 200 API reads per second, with one multipart upload per second. It measures an asset lookup, a 100-asset catch-up page, an app lookup and the upload create, sign and complete calls. A simulated encoder claims each job and reports a terminal result. The webhook goes to a receiver on the same host. The claim measurement starts when the job is queued. The webhook measurement starts when the event is written.
For this workload, the sizing objectives are 99.9% successful API requests, API p95 under 200 ms on each route, enqueue-to-claim p95 under 2 seconds with an available worker, and event-to-webhook p95 under 10 seconds with a healthy receiver. Remote worker wake-up, encoding time and internet latency add to the time an integration sees. Use the monitoring recording rules to track your own API response times and server errors.
The November 2026 run used a shared 2-vCPU ARM64 VM and PostgreSQL 18.6. ClipMux, Postgres and the load generator had 4 GiB of memory limits combined. Each column shows p50 / p95 in milliseconds over one minute.
| Operation | 10 reads/s | 50 reads/s | 100 reads/s | 200 reads/s |
|---|---|---|---|---|
| List 100 assets | 4.9 / 18.2 | 4.8 / 17.4 | 4.6 / 34.4 | 5.2 / 255.5 |
| Read an asset | 3.2 / 9.3 | 2.8 / 11.1 | 2.7 / 25.4 | 3.3 / 236.2 |
| Read app details | 2.8 / 10.8 | 2.5 / 8.0 | 2.5 / 20.1 | 2.6 / 229.9 |
| Create an upload | 7.8 / 22.2 | 7.9 / 26.2 | 7.8 / 34.6 | 11.9 / 197.5 |
| Sign upload parts | 2.7 / 10.4 | 2.6 / 11.2 | 3.2 / 12.4 | 5.8 / 132.6 |
| Complete an upload | 5.5 / 19.2 | 5.7 / 23.4 | 7.8 / 37.5 | 11.7 / 118.4 |
| Enqueue to claim | 401 / 986 | 402 / 968 | 468 / 972 | 448 / 991 |
| Event to webhook delivery | 2,373 / 4,516 | 2,551 / 4,642 | 2,481 / 4,810 | 2,446 / 4,559 |
The run met all four objectives through 100 reads/s plus one upload/s. At 200 reads/s, the three read routes exceeded the p95 objective and the load generator dropped 187 of 12,000 scheduled reads. Every read that reached ClipMux succeeded in this run.
With R2 storage, a 1 GiB upload takes 32 part PUTs of 32 MiB each. R2 receives all 1 GiB directly from the uploader. On a successful upload with one signing batch, ClipMux handles three API calls to create the upload, sign the parts and complete it. With Cloudflare Worker delivery and a video whose encoded files are in R2, 100 viewers averaging 5 Mbit/s each receive about 500 Mbit/s from Cloudflare. The ClipMux origin serves zero of those media bytes. Budget origin bandwidth separately for files still served through origin fallback.