Spaces:
Runtime error
Runtime error
Download Dockerfile from Shaunwg/MatcheringAI: direct link, hf CLI and curl.
- Browser
- Download file 945 Bytes
-
https://huggingface.co/spaces/Shaunwg/MatcheringAI/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/Shaunwg/MatcheringAI/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/Shaunwg/MatcheringAI/resolve/main/Dockerfile
945 Bytes
| # Use a base Python image with a specific version | |
| FROM python:3.10-slim-buster | |
| # Install system dependencies: ffmpeg and libsndfile1 | |
| # ffmpeg is crucial for matchering to handle various audio formats (mp3, flac, ogg, etc.) | |
| # libsndfile1 is often a dependency for sound processing libraries like SoundFile, which matchering uses. | |
| RUN apt-get update && apt-get install -y ffmpeg libsndfile1 && rm -rf /var/lib/apt/lists/* | |
| # Create a non-root user and set working directory to avoid permission issues | |
| RUN useradd -m -u 1000 user | |
| WORKDIR /app | |
| USER user | |
| # Copy requirements.txt and install Python dependencies | |
| COPY --chown=user:user requirements.txt . | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # Copy your application code | |
| COPY --chown=user:user . . | |
| # Expose the port your application will listen on (Hugging Face Spaces expects 7860 by default for Gradio) | |
| EXPOSE 7860 | |
| # Command to run your Gradio application | |
| CMD ["python", "app.py"] | |