-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
34 lines (27 loc) · 1.15 KB
/
Dockerfile
File metadata and controls
34 lines (27 loc) · 1.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
FROM python:3.10
RUN set -eux; \
\
apt-get update; \
apt-get install -y --no-install-recommends \
ca-certificates \
libgl1 \
vim \
; \
rm -r /var/lib/apt/lists/*; \
\
git clone https://github.com/AUTOMATIC1111/stable-diffusion-webui.git /root/stable-diffusion-webui;
WORKDIR /root/stable-diffusion-webui
RUN set -eux; \
\
pip install --no-cache-dir torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/cu117; \
pip install --no-cache-dir cython opencv-python-headless gfpgan open-clip-torch xformers pyngrok clip-anytorch; \
pip install --no-cache-dir -r requirements_versions.txt; \
\
python launch.py --exit --skip-torch-cuda-test; \
\
wget -O /root/stable-diffusion-webui/models/Stable-diffusion/v1-5-pruned-emaonly.safetensors \
https://huggingface.co/runwayml/stable-diffusion-v1-5/resolve/main/v1-5-pruned-emaonly.safetensors;
COPY docker-entrypoint.sh /usr/local/bin
ENTRYPOINT ["docker-entrypoint.sh"]
EXPOSE 7860 7861
CMD ["python", "launch.py"]