Spaces:
Sleeping
Sleeping
Download Dockerfile from Koottu/FaceMatch-Azure-Dev: direct link, hf CLI and curl.
- Browser
- Download file 809 Bytes
-
https://huggingface.co/spaces/Koottu/FaceMatch-Azure-Dev/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/Koottu/FaceMatch-Azure-Dev/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/Koottu/FaceMatch-Azure-Dev/resolve/main/Dockerfile
809 Bytes
| FROM python:3.10-slim | |
| # Build tools for InsightFace's Cython extension, plus shared libs OpenCV needs | |
| RUN apt-get update && apt-get install -y --no-install-recommends \ | |
| build-essential \ | |
| libgl1 \ | |
| libglib2.0-0 \ | |
| libsm6 \ | |
| libxext6 \ | |
| libxrender1 \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Hugging Face Spaces run the container as UID 1000 | |
| RUN useradd -m -u 1000 user | |
| USER user | |
| ENV HOME=/home/user \ | |
| PATH=/home/user/.local/bin:$PATH \ | |
| INSIGHTFACE_HOME=/tmp/.insightface \ | |
| MPLCONFIGDIR=/tmp/matplotlib | |
| WORKDIR $HOME/app | |
| COPY --chown=user requirements.txt . | |
| RUN pip install --no-cache-dir --upgrade pip && \ | |
| pip install --no-cache-dir -r requirements.txt | |
| COPY --chown=user . . | |
| EXPOSE 7860 | |
| CMD ["python", "-m", "uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"] | |