Spaces:
Sleeping
Sleeping
Download Dockerfile from K2MAR/mon-api-sd: direct link, hf CLI and curl.
- Browser
- Download file 527 Bytes
-
https://huggingface.co/spaces/K2MAR/mon-api-sd/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/K2MAR/mon-api-sd/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/K2MAR/mon-api-sd/resolve/main/Dockerfile
527 Bytes
| FROM python:3.10-slim | |
| ENV PYTHONUNBUFFERED=1 | |
| WORKDIR /app | |
| COPY api_server.py /app/ | |
| RUN apt-get update && apt-get install -y git && rm -rf /var/lib/apt/lists/* | |
| RUN pip install --no-cache-dir \ | |
| torch torchvision torchaudio \ | |
| --index-url https://download.pytorch.org/whl/cpu | |
| RUN pip install --no-cache-dir \ | |
| diffusers \ | |
| transformers \ | |
| safetensors \ | |
| peft \ | |
| flask \ | |
| pillow \ | |
| accelerate | |
| RUN mkdir -p /app/model /app/generated_images | |
| EXPOSE 7860 | |
| CMD ["python3", "-u", "/app/api_server.py"] |