Skip to content

Commit

Permalink
Modify installation extension dependencies (AbdBarho#518)
Browse files Browse the repository at this point in the history
Perform a full extension installation process instead of just installing
dependencies
Some extensions do not include `requirements.txt` but install
dependencies in `install.py`, and all extensions include `install.py`,
so it is safe to use it for extended dependency installation
This is because the extension development of AUTOMATIC1111's webui does
not require the existence of `requirements.txt` but uses `install.py` to
initialize the extension

https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Developing-extensions#installpy
  • Loading branch information
KagurazakaNyaa committed Jun 25, 2023
1 parent d0091b2 commit 4f73bc2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ services:
<<: *base_service
profiles: ["auto"]
build: ./services/AUTOMATIC1111
image: sd-auto:59
image: sd-auto:60
environment:
- CLI_ARGS=--allow-code --medvram --xformers --enable-insecure-extension-access --api

Expand Down
7 changes: 4 additions & 3 deletions services/AUTOMATIC1111/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,10 @@ chown -R root ~/.cache/
chmod 766 ~/.cache/

shopt -s nullglob
list=(./extensions/*/requirements.txt)
for req in "${list[@]}"; do
pip install -r "$req"
# For install.py, please refer to https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Developing-extensions#installpy
list=(./extensions/*/install.py)
for installscript in "${list[@]}"; do
PYTHONPATH=${ROOT} python "$installscript"
done

if [ -f "/data/config/auto/startup.sh" ]; then
Expand Down

0 comments on commit 4f73bc2

Please sign in to comment.