streaming / Dockerfile
rjzevallos's picture
Fix: Optimize build to prevent OOM - download model at runtime instead of build time
3e8e10c
raw
history blame contribute delete
541 Bytes
FROM python:3.10-slim
WORKDIR /app
# Instala dependencias del sistema necesarias
RUN apt-get update && apt-get install -y \
libsndfile1 \
ffmpeg \
git \
&& rm -rf /var/lib/apt/lists/*
# Copia requirements
COPY requirements.txt .
# Instala dependencias Python
RUN pip install --no-cache-dir -r requirements.txt
# Copia el código de la aplicación
COPY . .
# NO descargar el modelo aquí - se descarga en runtime
# Esto evita problemas de memoria durante el build
EXPOSE 7860
# Ejecuta la app
CMD ["python", "app.py"]