Replies: 3 comments 2 replies
-
great work! |
Beta Was this translation helpful? Give feedback.
-
It would be very helpful to have the ability to delete, back up, and restore volumes and images. I had networking issues. So, I wrote few scripts to store volumes and image to other machine. Someone might find these useful if they need to make a quick restoring point or multi testing deployment environment on another machines. (busybox or ubuntu image are required for volume backup and resorting) For volumes (backup and resorting):
This to restore the two backup volumes ,
For image (save and load): |
Beta Was this translation helpful? Give feedback.
-
Running this on a headless linux server (with gpus)
Any idea? |
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. Minimal information is baked into the image to allow for easy updates without rebuilding.
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.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 (WIP)
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.
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
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.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