Files
pluto 8aa42e6fcb fix: add gcc/build-essential for webrtcvad, drop silero-vad pip install
resemblyzer depends on webrtcvad which compiles C extensions — gcc and
build-essential are required in slim containers. silero-vad pip package
has a broken native .so in python:3.12-slim; VAD model is now loaded at
runtime via torch.hub.load() which downloads on first use.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-28 13:17:32 -05:00

20 lines
674 B
Docker

FROM python:3.12-slim
RUN apt-get update && apt-get install -y --no-install-recommends \
libsndfile1 gcc build-essential && rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY pyproject.toml .
# Install torch CPU-only, resemblyzer, and cron deps
# silero-vad pip package excluded — not needed in cron (no VAD processing)
RUN pip install --no-cache-dir torch --index-url https://download.pytorch.org/whl/cpu && \
pip install --no-cache-dir resemblyzer scipy numpy httpx pydantic-settings
COPY app/ app/
# Pre-download resemblyzer model
RUN python -c "from resemblyzer import VoiceEncoder; VoiceEncoder()"
ENV PYTHONUNBUFFERED=1
CMD ["python", "-m", "app.cron.main"]