Spaces:
Runtime error
Runtime error
| FROM python:3.10-slim | |
| ENV PYTHONDONTWRITEBYTECODE=1 | |
| ENV PYTHONUNBUFFERED=1 | |
| ENV TRANSFORMERS_CACHE=/tmp/huggingface | |
| WORKDIR /app | |
| # Install system dependencies | |
| RUN apt-get update && apt-get install -y \ | |
| gcc \ | |
| g++ \ | |
| make \ | |
| python3-dev \ | |
| libpq-dev \ | |
| portaudio19-dev \ | |
| libasound-dev \ | |
| ffmpeg \ | |
| libsndfile1 \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Copy and install Python dependencies | |
| COPY requirements.txt . | |
| RUN pip install --upgrade pip && pip install --no-cache-dir -r requirements.txt | |
| # Copy your actual app | |
| COPY . . | |
| # Set permissions (optional if needed) | |
| RUN chmod -R 777 /app | |
| EXPOSE 7860 | |
| # Run your FastAPI app | |
| CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"] | |