mirror of
https://github.com/myronblair/kino-app
synced 2026-07-28 05:23:45 -05:00
24 lines
672 B
Docker
24 lines
672 B
Docker
# Kino backend — FastAPI + ffmpeg
|
|
FROM python:3.11-slim
|
|
|
|
# ffmpeg for HLS transcoding; util-linux for `nice` (already in base but explicit)
|
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
ffmpeg \
|
|
curl \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
WORKDIR /app
|
|
|
|
# Install Python deps first (layer cache)
|
|
COPY requirements.txt .
|
|
RUN pip install --no-cache-dir -r requirements.txt
|
|
|
|
# Copy app source
|
|
COPY . .
|
|
|
|
# Create media dirs (will be overridden by volume mount at runtime)
|
|
RUN mkdir -p /media/videos /media/posters /media/subtitles /media/hls
|
|
|
|
EXPOSE 8001
|
|
CMD ["uvicorn", "server:app", "--host", "0.0.0.0", "--port", "8001", "--proxy-headers"]
|