Spaces:
Runtime error
Runtime error
FROM python:3.10-slim | |
WORKDIR /app | |
# Install system dependencies needed for audio & builds | |
RUN apt-get update && apt-get install -y \ | |
git \ | |
build-essential \ | |
ffmpeg \ | |
libsndfile1 \ | |
&& rm -rf /var/lib/apt/lists/* | |
ENV NLTK_DATA=/app/nltk_data | |
RUN mkdir -p /app/nltk_data | |
# Copy requirements first to leverage Docker cache | |
COPY requirements.txt . | |
# Install Python dependencies, including MeloTTS from git (add it to requirements.txt) | |
RUN pip install --no-cache-dir -r requirements.txt | |
# Run unidic download (needed by your app) | |
RUN python -m unidic download | |
# Copy the rest of the app code | |
COPY . . | |
# Expose the port your Gradio app uses (default 7860) | |
EXPOSE 7860 | |
# Run your app | |
CMD ["python", "app.py"] | |