projects / Dockerfile
rixxabh's picture
Upload 11 files
8d5da31 verified
raw
history blame contribute delete
548 Bytes
FROM python:3.11-slim
WORKDIR /app
# System dependencies for OpenCV
RUN apt-get update && apt-get install -y \
libgl1 \
libglib2.0-0 \
libsm6 \
libxext6 \
libxrender1 \
libgomp1 \
&& rm -rf /var/lib/apt/lists/*
# Install Python deps
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy app code
COPY . .
# Download model files at build time
RUN python download_models.py
EXPOSE 5000
CMD ["gunicorn", "--bind", "0.0.0.0:5000", "--timeout", "120", "app:app"]