Spaces:
Runtime error
Runtime error
## Base image with Python | |
FROM python:3.10-slim | |
# Set working directory | |
WORKDIR /app | |
# Prevent Numba caching issues with Librosa | |
ENV NUMBA_CACHE_DIR=/tmp/numba_cache | |
# OR disable JIT completely (uncomment if needed) | |
# ENV NUMBA_DISABLE_JIT=1 | |
# Create writable cache dir for Numba | |
RUN mkdir -p /tmp/numba_cache | |
# Install OS-level dependencies | |
RUN apt-get update && apt-get install -y \ | |
ffmpeg \ | |
git \ | |
&& rm -rf /var/lib/apt/lists/* | |
# Copy requirements and install Python packages | |
COPY requirements.txt ./ | |
RUN pip install --no-cache-dir -r requirements.txt | |
# Copy the rest of your project files | |
COPY . . | |
# Expose the correct port for Streamlit on Hugging Face Spaces | |
EXPOSE 7860 | |
# Launch Streamlit app (Hugging Face expects port 7860) | |
CMD ["streamlit", "run", "src/app.py", "--server.port=7860", "--server.address=0.0.0.0"] | |