Spaces:
Sleeping
Sleeping
File size: 652 Bytes
9bc686b fe6c464 9bc686b 4083163 9bc686b | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | FROM python:3.12-slim
# Install system dependencies for OpenCV and pyttsx3/espeak
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential \
libgl1 \
libglib2.0-0 \
espeak \
alsa-utils \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /workspace
# Copy and install python dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy backend code
COPY . .
# Download ONNX model weights during container build
RUN python app/core/download_models.py
# Expose FastAPI port
EXPOSE 8000
# Run FastAPI app
CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "8000"]
|