Skip to content

Add Docker support#73

Draft
Copilot wants to merge 3 commits into
mainfrom
copilot/docker-support-containerization
Draft

Add Docker support#73
Copilot wants to merge 3 commits into
mainfrom
copilot/docker-support-containerization

Conversation

Copilot AI commented Apr 5, 2026

Copy link
Copy Markdown

Containerize tplay so it works out of the box without manually installing Rust, FFmpeg, libmpv, or other system dependencies.

Changes

  • Dockerfile: Multi-stage build — rust:bookworm for compilation, debian:bookworm-slim for runtime. Includes ffmpeg, libmpv2, yt-dlp, and ALSA in the runtime image. WORKDIR /media for convenient volume mounts.
  • .dockerignore: Excludes .git, target/, media files, IDE configs from build context.
  • README.md: Added Docker section with build/run examples covering local files, YouTube, remote URLs, and webcam passthrough.

Usage

docker build -t tplay .
docker run --rm -it -v ./video.mp4:/media/video.mp4 tplay video.mp4
docker run --rm -it tplay https://www.youtube.com/watch?v=dQw4w9WgXcQ

Copilot AI linked an issue Apr 5, 2026 that may be closed by this pull request
Copilot AI changed the title [WIP] Add Docker support for easy setup Add Docker support Apr 5, 2026
Copilot AI requested a review from maxcurzi April 5, 2026 02:48
…o EOF handling

- Docker: Add ALSA null config, PIPEWIRE_DEBUG=0, and TPLAY_AO=null to support headless execution
- MPV: Add support for TPLAY_AO env var to override audio output driver via Mpv::with_initializer
- Pipeline: Fix frame send race condition by processing frame before select! send
- Sync: Implement audio EOF detection in PlaybackClock to allow final video frames to drain and --auto-exit to work correctly in Docker
- Pipeline: Increase frame channel buffer to 2 for better throughput under load
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Docker Support

2 participants