Spaces:
Sleeping
Sleeping
| FROM python:3.10-slim | |
| WORKDIR /app | |
| ENV PYTHONDONTWRITEBYTECODE=1 \ | |
| PYTHONUNBUFFERED=1 \ | |
| PIP_NO_CACHE_DIR=1 \ | |
| PIP_DISABLE_PIP_VERSION_CHECK=1 \ | |
| PIP_ROOT_USER_ACTION=ignore | |
| # Base image already bundles PyTorch + deps so we install only the minimal OS tools we still need | |
| RUN apt-get update && apt-get install -y --no-install-recommends \ | |
| ffmpeg \ | |
| libsndfile1 \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Copy only dependency manifests first for better Docker layer caching | |
| COPY requirements.txt ./ | |
| RUN pip install --no-cache-dir --upgrade pip setuptools wheel \ | |
| && pip install --no-cache-dir -r requirements.txt | |
| COPY . . | |
| # Gradio defaults to 7860; change if you override `demo.launch(server_port=...)` | |
| ENV PORT=7860 | |
| EXPOSE 7860 | |
| CMD ["python", "app.py"] | |