Replies: 6 comments 22 replies
-
Trying this on an unraid system and getting a looped error:
Which links to this script and it fails right on the setup trying to pull in the python/pip package cv2 |
Beta Was this translation helpful? Give feedback.
-
Instructions tested working with clean checkout
Test Note: I had already run into some issues with line endings on my original install, not sure exactly what I did to fix, didn't need do anything this time around but may have already had changes applied globally. Other Notes: This is beyond the scope of this documentation, but for my normal setup I'm also using a docker-compose.override.yml file to change container network settings and run a VPN alongside the sd container for remote access. After testing, when I reapplied my override I went to rebuild/launch my normal setup (via docker-compose up --build -d) and got rpc errors from the docker registry for the cuda image. accessing that address from a web browser, I got: Might be a rate limit thing? I retried a couple times over the course of a couple minutes and it eventually went through without changing anything. Not an error in the repo, just something to be aware of in case bug reports show up with that error. Edit: oh, also I'm using |
Beta Was this translation helpful? Give feedback.
-
What about moving this guide to the Wiki, under the Installation section? This would make it more visible. |
Beta Was this translation helpful? Give feedback.
-
Updated the guide with some info regarding the recent merge from dev. Two big things to note is the models the entrypoint.sh script downloads will now be stored in a new directory called Also added a dependency for LDSR in the environment.yaml file which was also named |
Beta Was this translation helpful? Give feedback.
-
It appears the docker setup was revamped in October: anybody have any guidance on how to run the latest within docker? |
Beta Was this translation helpful? Give feedback.
-
There's no |
Beta Was this translation helpful? Give feedback.
-
Overview
The current implementation is intended to create the bare minimum environment to run the code in the repository while keeping system-level dependencies isolated to the container or its volumes. Minimal information is baked into the image itself to allow for easy updates without rebuilding it.
The Dockerfile will create an image on your system that has Nvidia drivers, CUDA and Miniconda installed. The
entrypoint.sh
script handles the remaining requirements of the application such as installing the conda env, downloading required model files and launching the webgui when the container is started.2 volumes are created to cache the conda and pip dependencies and reduce needing to recreate/download them on container restarts/rebuilds.
The code from the repository is mounted in the container at
/sd
. Image output will be found in./outputs
on your system as expected.A recent update adds caching all model files the script downloads into the directory
./model_cache
with the filenames formatted as<filename>.<sha256sum>
This allows you to symlink the directory outside of the source directory if desired and prevents needing to re-download these files if you need to re-setup the repository locally.Requirements
Setup
Initial installation will take some time, probably 10-20 mins depending on your system and internet connection.
You can stop the container with
CTRL-C
and restart it later by simply runningdocker compose up
Windows Setup
nvidia-smi
in the command lineMake sure that your git is not converting newlines into Windows format differently from the repository
Please comment if you got everything running successfully and any special steps needed.
Updating
This will only rebuild layers that have changed in the Dockerfile. Other environment changes should be handled by
entrypoint.sh
and then any new code for the webgui will be launched.This error might occur after renaming the egg info for this repository so that it does not collide with other needed dependencies.
To resolve this please run the following:
Customization
There is now an
.env_docker
file that contains some parameters you can use to customize your setup. Generally suggest using the defaults for initial setup then you can play with the variables to your liking. For lower ram systems you might need to use one of the optimized modes to complete your setup e.g.WEBUI_ARGS=--optimized
Troubleshooting
A helper script has been provided to clean the docker environment of the container, image and volumes. Please inspect
docker-reset.sh
for the relevant commands in bash if you need to recreate the steps on another OS.Beta Was this translation helpful? Give feedback.
All reactions