Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files12345678910113 unmodified lines1516171819202122FROM python:3.10-slimENV PYTHONUNBUFFERED=1ENV HF_HOME=/home/appuser/.cache/huggingfaceENV TORCH_HOME=/home/appuser/.cache/torchENV PIP_NO_CACHE_DIR=1RUN apt-get update && apt-get install -y ffmpeg git libsndfile1 && rm -rf /var/lib/apt/lists/*WORKDIR /app3 unmodified linesCOPY . .RUN python js/download_model.pyEXPOSE 7860CMD ["uvicorn","js.app:app","--host","0.0.0.0","--port","7860"]1234567891011121314153 unmodified lines1920212223242526272829FROM python:3.10-slimENV PYTHONUNBUFFERED=1ENV HF_HOME=/root/.cache/huggingfaceENV TORCH_HOME=/root/.cache/torchENV PIP_NO_CACHE_DIR=1RUN apt-get update && apt-get install -y \ffmpeg \git \libsndfile1 \&& rm -rf /var/lib/apt/lists/*WORKDIR /app3 unmodified linesCOPY . .# Run from the js/ subdirectory so relative imports workRUN cd /app/js && python download_model.pyEXPOSE 7860# Launch uvicorn with --app-dir pointing at js/ so it finds app.py as# a top-level module (avoids the js.app package resolution overhead)CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860", "--app-dir", "/app/js"]
Dockerfile+12-5