Let the user pause and resume the in-flight encode from the dashboard.
ffmpeg has no built-in pause, but on Linux the running process can be frozen with SIGSTOP and resumed with SIGCONT. It is the same process with all state and the partial output.mkv intact, so it resumes exactly where it left off - no re-encode, no corruption. libsvtav1 runs in-process (no forked children), so signalling the ffmpeg process suspends all its SVT-AV1 threads at once.
Wiring:
Encoder publishes the running *os.Process to a control handle (mutex-guarded; set on start, cleared on finish in runCmdProgress).
Add Pause()/Resume() that call proc.Signal(SIGSTOP/SIGCONT). Consider Setpgid + signalling the process group as belt-and-suspenders.
Expose POST /api/pause and /api/resume; add a button on the dashboard.
Add a 'paused' state to the tracker.
Caveats:
RAM stays resident while paused (SVT-AV1 buffers are not released - it just stops using CPU). Not a way to free memory.
ETA/elapsed must account for paused time or they drift (elapsed keeps ticking, speed goes stale). Freeze them while paused.
SIGTERM/Ctrl-C shutdown still works while paused (context-cancel uses SIGKILL, which lands on a stopped process).
podman pause is too coarse - it freezes the whole container (daemon + web UI), not just one encode.
Mutation, so it shares the auth consideration in #2 (deferred on the isolated network).
Let the user pause and resume the in-flight encode from the dashboard.
ffmpeg has no built-in pause, but on Linux the running process can be frozen with SIGSTOP and resumed with SIGCONT. It is the same process with all state and the partial output.mkv intact, so it resumes exactly where it left off - no re-encode, no corruption. libsvtav1 runs in-process (no forked children), so signalling the ffmpeg process suspends all its SVT-AV1 threads at once.
Wiring:
- Encoder publishes the running *os.Process to a control handle (mutex-guarded; set on start, cleared on finish in runCmdProgress).
- Add Pause()/Resume() that call proc.Signal(SIGSTOP/SIGCONT). Consider Setpgid + signalling the process group as belt-and-suspenders.
- Expose POST /api/pause and /api/resume; add a button on the dashboard.
- Add a 'paused' state to the tracker.
Caveats:
- RAM stays resident while paused (SVT-AV1 buffers are not released - it just stops using CPU). Not a way to free memory.
- ETA/elapsed must account for paused time or they drift (elapsed keeps ticking, speed goes stale). Freeze them while paused.
- SIGTERM/Ctrl-C shutdown still works while paused (context-cancel uses SIGKILL, which lands on a stopped process).
- podman pause is too coarse - it freezes the whole container (daemon + web UI), not just one encode.
Mutation, so it shares the auth consideration in #2 (deferred on the isolated network).
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Let the user pause and resume the in-flight encode from the dashboard.
ffmpeg has no built-in pause, but on Linux the running process can be frozen with SIGSTOP and resumed with SIGCONT. It is the same process with all state and the partial output.mkv intact, so it resumes exactly where it left off - no re-encode, no corruption. libsvtav1 runs in-process (no forked children), so signalling the ffmpeg process suspends all its SVT-AV1 threads at once.
Wiring:
Caveats:
Mutation, so it shares the auth consideration in #2 (deferred on the isolated network).