initial commmit

A video player controller for the video player node
This commit is contained in:
Media
2026-06-14 14:34:34 -05:00
commit fc27feaea1
6 changed files with 1164 additions and 0 deletions
+32
View File
@@ -0,0 +1,32 @@
FROM python:3.12-slim
# System deps: ffmpeg for muxing, nodejs for yt-dlp JS runtime, ca-certs for TLS
RUN apt-get update && apt-get install -y --no-install-recommends \
ffmpeg \
nodejs \
ca-certificates \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Optional but strongly recommended: keep yt-dlp fresh (only if installed via pip)
RUN python -m pip install --no-cache-dir -U yt-dlp
# Make yt-dlp defaults persistent (so your subprocess call doesn't need flags)
# 1) tell yt-dlp to use node as JS runtime
# 2) (optional) force android client to dodge SABR weirdness more often
RUN mkdir -p /etc/yt-dlp && printf "%s\n" \
"--js-runtimes node" \
"--extractor-args youtube:player_client=android" \
> /etc/yt-dlp.conf
COPY app.py ./app.py
COPY controller_core.py ./controller_core.py
ENV PYTHONUNBUFFERED=1
EXPOSE 8000
CMD ["python", "app.py"]