Spaces:
Paused
Paused
Download Dockerfile from junaid-simamdigital/Simam3D: direct link, hf CLI and curl.
- Browser
- Download file 1.24 kB
-
https://huggingface.co/spaces/junaid-simamdigital/Simam3D/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/junaid-simamdigital/Simam3D/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/junaid-simamdigital/Simam3D/resolve/main/Dockerfile
1.24 kB
| FROM nvidia/cuda:12.4.1-cudnn-runtime-ubuntu22.04 | |
| ENV DEBIAN_FRONTEND=noninteractive \ | |
| PYTHONUNBUFFERED=1 \ | |
| GRADIO_SERVER_NAME=0.0.0.0 \ | |
| GRADIO_SERVER_PORT=7860 \ | |
| HF_HOME=/home/user/.cache/huggingface \ | |
| PYTORCH_CUDA_ALLOC_CONF=expandable_segments:True | |
| RUN apt-get update && apt-get install -y --no-install-recommends \ | |
| python3.10 python3-pip git libgl1 libglib2.0-0 \ | |
| && rm -rf /var/lib/apt/lists/* | |
| RUN useradd -m -u 1000 user | |
| USER user | |
| ENV HOME=/home/user PATH=/home/user/.local/bin:$PATH | |
| WORKDIR /home/user/app | |
| COPY --chown=user . /home/user/app | |
| RUN python3.10 -m pip install --user --upgrade pip && \ | |
| python3.10 -m pip install --user --no-cache-dir -r requirements.txt | |
| # Keep the baseline image buildable when the experimental DA3 API changes. | |
| # GPU research builders can opt in with --build-arg SIMAM3D_INSTALL_DA3=1. | |
| ARG SIMAM3D_INSTALL_DA3=0 | |
| RUN if [ "$SIMAM3D_INSTALL_DA3" = "1" ]; then \ | |
| python3.10 -m pip install --user --no-cache-dir -r requirements-da3.txt; \ | |
| fi | |
| EXPOSE 7860 | |
| HEALTHCHECK --interval=30s --timeout=5s --start-period=120s --retries=3 \ | |
| CMD python3.10 -c "import urllib.request; urllib.request.urlopen('http://127.0.0.1:7860/', timeout=4)" | |
| CMD ["python3.10", "app.py"] | |