Skip to content

Commit

Permalink
Update Auto (#379)
Browse files Browse the repository at this point in the history
Last version before pytorch 2


AUTOMATIC1111/stable-diffusion-webui@5ab7f21
  • Loading branch information
AbdBarho authored May 4, 2023
1 parent 7b8bc3d commit 56b9422
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ services:
<<: *base_service
profiles: ["auto"]
build: ./services/AUTOMATIC1111
image: sd-auto:52
image: sd-auto:53
environment:
- CLI_ARGS=--allow-code --medvram --xformers --enable-insecure-extension-access --api

Expand Down
10 changes: 6 additions & 4 deletions services/AUTOMATIC1111/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,9 @@ FROM python:3.10.9-slim

ENV DEBIAN_FRONTEND=noninteractive PIP_PREFER_BINARY=1

RUN --mount=type=cache,target=/root/.cache/pip \
pip install torch==1.13.1+cu117 torchvision --extra-index-url https://download.pytorch.org/whl/cu117
RUN --mount=type=cache,target=/root/.cache/pip pip install torch==1.13.1+cu117 torchvision --extra-index-url https://download.pytorch.org/whl/cu117

# RUN --mount=type=cache,target=/root/.cache/pip pip install torch==2.0.0+cu118 torchvision --extra-index-url https://download.pytorch.org/whl/cu117

RUN apt-get update && apt install fonts-dejavu-core rsync git jq moreutils -y && apt-get clean

Expand Down Expand Up @@ -61,7 +62,7 @@ RUN --mount=type=cache,target=/root/.cache/pip \
RUN apt-get -y install libgoogle-perftools-dev && apt-get clean
ENV LD_PRELOAD=libtcmalloc.so

ARG SHA=a9fed7c364061ae6efb37f797b6b522cb3cf7aa2
ARG SHA=5ab7f213bec2f816f9c5644becb32eb72c8ffb89
RUN --mount=type=cache,target=/root/.cache/pip \
cd stable-diffusion-webui && \
git fetch && \
Expand All @@ -76,7 +77,8 @@ RUN \
python3 /docker/info.py ${ROOT}/modules/ui.py && \
mv ${ROOT}/style.css ${ROOT}/user.css && \
# one of the ugliest hacks I ever wrote \
sed -i 's/in_app_dir = .*/in_app_dir = True/g' /usr/local/lib/python3.10/site-packages/gradio/routes.py
sed -i 's/in_app_dir = .*/in_app_dir = True/g' /usr/local/lib/python3.10/site-packages/gradio/routes.py && \
git config --global --add safe.directory '*'

WORKDIR ${ROOT}
ENV NVIDIA_DRIVER_CAPABILITIES=compute,utility
Expand Down

0 comments on commit 56b9422

Please sign in to comment.