FROM python:3.11-slim WORKDIR /app # Install system dependencies for librosa RUN apt-get update && apt-get install -y \ libsndfile1 \ ffmpeg \ && rm -rf /var/lib/apt/lists/* # Copy requirements and install Python dependencies COPY requirements.txt . RUN pip install --no-cache-dir -r requirements.txt # Copy application code COPY . . # Expose the port Gradio will run on EXPOSE 7860 # Set Gradio to bind to all interfaces in Docker ENV GRADIO_SERVER_NAME="0.0.0.0" # Command to run the application CMD ["python", "app.py"]