FROM python:3.10 # Install system dependencies RUN apt-get update && \ apt-get install -y ffmpeg libsndfile1 git-lfs && \ git lfs install # Create non-root user RUN useradd -m -u 1000 user USER user ENV PATH="/home/user/.local/bin:$PATH" WORKDIR /app # Copy requirements first (better Docker caching) COPY --chown=user requirements.txt requirements.txt RUN pip install --no-cache-dir --upgrade pip RUN pip install --no-cache-dir -r requirements.txt # Copy entire repo (including pyharp folder) COPY --chown=user . /app EXPOSE 7860 CMD ["python", "app.py"]