mirror of
https://github.com/AbdBarho/stable-diffusion-webui-docker.git
synced 2026-02-06 15:44:19 +01:00
initial checkin of server stuff
This commit is contained in:
parent
8ac4dd43ef
commit
4acf8e4402
|
|
@ -2,18 +2,19 @@ version: '3.9'
|
||||||
|
|
||||||
x-base_service: &base_service
|
x-base_service: &base_service
|
||||||
ports:
|
ports:
|
||||||
- "${WEBUI_PORT:-7860}:7860"
|
- "${WEBUI_PORT:-7880}:7880"
|
||||||
volumes:
|
volumes:
|
||||||
- &v1 ./data:/data
|
- &v1 ./data:/data
|
||||||
- &v2 ./output:/output
|
- &v2 ./output:/output
|
||||||
stop_signal: SIGKILL
|
stop_signal: SIGKILL
|
||||||
|
restart: always
|
||||||
tty: true
|
tty: true
|
||||||
deploy:
|
deploy:
|
||||||
resources:
|
resources:
|
||||||
reservations:
|
reservations:
|
||||||
devices:
|
devices:
|
||||||
- driver: nvidia
|
- driver: nvidia
|
||||||
device_ids: ['0']
|
device_ids: ["0"]
|
||||||
capabilities: [compute, utility]
|
capabilities: [compute, utility]
|
||||||
|
|
||||||
name: webui-docker
|
name: webui-docker
|
||||||
|
|
@ -30,8 +31,9 @@ services:
|
||||||
profiles: ["auto"]
|
profiles: ["auto"]
|
||||||
build: ./services/AUTOMATIC1111
|
build: ./services/AUTOMATIC1111
|
||||||
image: sd-auto:63
|
image: sd-auto:63
|
||||||
|
restart: always
|
||||||
environment:
|
environment:
|
||||||
- CLI_ARGS=--allow-code --medvram --xformers --enable-insecure-extension-access --api
|
- CLI_ARGS=--allow-code --medvram --enable-insecure-extension-access --xformers --api --listen --port 7880 --ckpt models/Stable-diffusion/sd_xl_base_1.0.safetensors
|
||||||
|
|
||||||
auto-cpu:
|
auto-cpu:
|
||||||
<<: *automatic
|
<<: *automatic
|
||||||
|
|
|
||||||
|
|
@ -44,9 +44,15 @@ RUN --mount=type=cache,target=/cache --mount=type=cache,target=/root/.cache/pip
|
||||||
RUN --mount=type=cache,target=/root/.cache/pip \
|
RUN --mount=type=cache,target=/root/.cache/pip \
|
||||||
git clone https://github.com/AUTOMATIC1111/stable-diffusion-webui.git && \
|
git clone https://github.com/AUTOMATIC1111/stable-diffusion-webui.git && \
|
||||||
cd stable-diffusion-webui && \
|
cd stable-diffusion-webui && \
|
||||||
git reset --hard 20ae71faa8ef035c31aa3a410b707d792c8203a3 && \
|
git switch dev && \
|
||||||
|
git pull && \
|
||||||
|
git fetch && \
|
||||||
pip install -r requirements_versions.txt
|
pip install -r requirements_versions.txt
|
||||||
|
|
||||||
|
|
||||||
|
# git reset --hard 20ae71faa8ef035c31aa3a410b707d792c8203a3 && \
|
||||||
|
# pip install -r requirements_versions.txt
|
||||||
|
|
||||||
RUN --mount=type=cache,target=/root/.cache/pip \
|
RUN --mount=type=cache,target=/root/.cache/pip \
|
||||||
--mount=type=bind,from=xformers,source=/wheel.whl,target=/xformers-0.0.21.dev544-cp310-cp310-manylinux2014_x86_64.whl \
|
--mount=type=bind,from=xformers,source=/wheel.whl,target=/xformers-0.0.21.dev544-cp310-cp310-manylinux2014_x86_64.whl \
|
||||||
pip install /xformers-0.0.21.dev544-cp310-cp310-manylinux2014_x86_64.whl
|
pip install /xformers-0.0.21.dev544-cp310-cp310-manylinux2014_x86_64.whl
|
||||||
|
|
@ -61,9 +67,12 @@ RUN --mount=type=cache,target=/root/.cache/pip \
|
||||||
|
|
||||||
RUN --mount=type=cache,target=/root/.cache/pip \
|
RUN --mount=type=cache,target=/root/.cache/pip \
|
||||||
pip install pyngrok \
|
pip install pyngrok \
|
||||||
git+https://github.com/TencentARC/GFPGAN.git@8d2447a2d918f8eba5a4a01463fd48e45126a379 \
|
git+https://github.com/openai/CLIP.git \
|
||||||
git+https://github.com/openai/CLIP.git@d50d76daa670286dd6cacf3bcd80b5e4823fc8e1 \
|
git+https://github.com/TencentARC/GFPGAN.git
|
||||||
git+https://github.com/mlfoundations/open_clip.git@bb6e834e9c70d9c27d0dc3ecedeebeaeb1ffad6b
|
|
||||||
|
# git+https://github.com/TencentARC/GFPGAN.git@8d2447a2d918f8eba5a4a01463fd48e45126a379 \
|
||||||
|
# git+https://github.com/openai/CLIP.git@d50d76daa670286dd6cacf3bcd80b5e4823fc8e1 \
|
||||||
|
# git+https://github.com/mlfoundations/open_clip.git@bb6e834e9c70d9c27d0dc3ecedeebeaeb1ffad6b
|
||||||
|
|
||||||
# Note: don't update the sha of previous versions because the install will take forever
|
# Note: don't update the sha of previous versions because the install will take forever
|
||||||
# instead, update the repo state in a later step
|
# instead, update the repo state in a later step
|
||||||
|
|
@ -72,12 +81,12 @@ RUN --mount=type=cache,target=/root/.cache/pip \
|
||||||
RUN apt-get -y install libgoogle-perftools-dev && apt-get clean
|
RUN apt-get -y install libgoogle-perftools-dev && apt-get clean
|
||||||
ENV LD_PRELOAD=libtcmalloc.so
|
ENV LD_PRELOAD=libtcmalloc.so
|
||||||
|
|
||||||
ARG SHA=68f336bd994bed5442ad95bad6b6ad5564a5409a
|
#ARG SHA=68f336bd994bed5442ad95bad6b6ad5564a5409a
|
||||||
RUN --mount=type=cache,target=/root/.cache/pip \
|
#RUN --mount=type=cache,target=/root/.cache/pip \
|
||||||
cd stable-diffusion-webui && \
|
# cd stable-diffusion-webui && \
|
||||||
git fetch && \
|
# git fetch && \
|
||||||
git reset --hard ${SHA} && \
|
# git reset --hard ${SHA} && \
|
||||||
pip install -r requirements_versions.txt
|
# pip install -r requirements_versions.txt
|
||||||
|
|
||||||
COPY . /docker
|
COPY . /docker
|
||||||
|
|
||||||
|
|
@ -91,6 +100,6 @@ RUN \
|
||||||
WORKDIR ${ROOT}
|
WORKDIR ${ROOT}
|
||||||
ENV NVIDIA_VISIBLE_DEVICES=all
|
ENV NVIDIA_VISIBLE_DEVICES=all
|
||||||
ENV CLI_ARGS=""
|
ENV CLI_ARGS=""
|
||||||
EXPOSE 7860
|
EXPOSE 7880
|
||||||
ENTRYPOINT ["/docker/entrypoint.sh"]
|
ENTRYPOINT ["/docker/entrypoint.sh"]
|
||||||
CMD python -u webui.py --listen --port 7860 ${CLI_ARGS}
|
CMD python -u webui.py ${CLI_ARGS}
|
||||||
|
|
|
||||||
|
|
@ -17,15 +17,7 @@ echo "Downloading, this might take a while..."
|
||||||
|
|
||||||
aria2c -x 10 --disable-ipv6 --input-file /docker/links.txt --dir /data/models --continue
|
aria2c -x 10 --disable-ipv6 --input-file /docker/links.txt --dir /data/models --continue
|
||||||
|
|
||||||
echo "Checking SHAs..."
|
|
||||||
|
|
||||||
parallel --will-cite -a /docker/checksums.sha256 "echo -n {} | sha256sum -c"
|
|
||||||
|
|
||||||
cat <<EOF
|
cat <<EOF
|
||||||
By using this software, you agree to the following licenses:
|
Downloads complete.
|
||||||
https://github.com/AbdBarho/stable-diffusion-webui-docker/blob/master/LICENSE
|
|
||||||
https://github.com/CompVis/stable-diffusion/blob/main/LICENSE
|
|
||||||
https://github.com/AUTOMATIC1111/stable-diffusion-webui/blob/master/LICENSE.txt
|
|
||||||
https://github.com/invoke-ai/InvokeAI/blob/main/LICENSE
|
|
||||||
And licenses of all UIs, third party libraries, and extensions.
|
|
||||||
EOF
|
EOF
|
||||||
|
|
|
||||||
|
|
@ -1,16 +1,4 @@
|
||||||
https://huggingface.co/runwayml/stable-diffusion-v1-5/resolve/main/v1-5-pruned-emaonly.ckpt
|
https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0/resolve/main/sd_xl_base_1.0.safetensors
|
||||||
out=Stable-diffusion/v1-5-pruned-emaonly.ckpt
|
out=Stable-diffusion/sd_xl_base_1.0.safetensors
|
||||||
https://huggingface.co/stabilityai/sd-vae-ft-mse-original/resolve/main/vae-ft-mse-840000-ema-pruned.ckpt
|
https://huggingface.co/stabilityai/stable-diffusion-xl-refiner-1.0/resolve/main/sd_xl_refiner_1.0.safetensors
|
||||||
out=VAE/vae-ft-mse-840000-ema-pruned.ckpt
|
out=Stable-diffusion/sd_xl_refiner_1.0.safetensors
|
||||||
https://huggingface.co/runwayml/stable-diffusion-inpainting/resolve/main/sd-v1-5-inpainting.ckpt
|
|
||||||
out=Stable-diffusion/sd-v1-5-inpainting.ckpt
|
|
||||||
https://github.com/TencentARC/GFPGAN/releases/download/v1.3.4/GFPGANv1.4.pth
|
|
||||||
out=GFPGAN/GFPGANv1.4.pth
|
|
||||||
https://github.com/xinntao/Real-ESRGAN/releases/download/v0.1.0/RealESRGAN_x4plus.pth
|
|
||||||
out=RealESRGAN/RealESRGAN_x4plus.pth
|
|
||||||
https://github.com/xinntao/Real-ESRGAN/releases/download/v0.2.2.4/RealESRGAN_x4plus_anime_6B.pth
|
|
||||||
out=RealESRGAN/RealESRGAN_x4plus_anime_6B.pth
|
|
||||||
https://heibox.uni-heidelberg.de/f/31a76b13ea27482981b4/?dl=1
|
|
||||||
out=LDSR/project.yaml
|
|
||||||
https://heibox.uni-heidelberg.de/f/578df07c8fc04ffbadf3/?dl=1
|
|
||||||
out=LDSR/model.ckpt
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue