Description •
Requirements •
Pre-installation Steps •
Installation
Execution •
Configuration •
Storage •
Known Issues •
Credits
This project is made for running ComfyUI easily on Docker, providing an easy configuration that can be adapted for image generation AI's. The default configuration and some parts of this README are based on the Flux.1-Schnell FP8
model.
Required | Recommended | |
---|---|---|
GPU |
NVIDIA (with CUDA) | NVIDIA (with CUDA) |
GPU VRAM |
4 GB | 8 GB |
CPU |
4 cores/threads | 8 cores/threads |
DRAM |
16 GB | 32 GB |
Disk space |
30 GB | 50 GB |
CUDA Toolkit |
Required (not required for Docker) | Required (not required for Docker) |
NVIDIA Container Toolkit |
Required on Linux | Required on Linux |
-
Install NVIDIA Container Toolkit:
- Refer to the official documentation for detailed instructions.
-
Verify NVIDIA driver version: Ensure that you are running the newest compatible version of the NVIDIA driver.
- Verify NVIDIA driver version: Ensure that you are running the newest compatible version of the NVIDIA driver.
-
Clone the main repository:
git clone https://github.com/TD99/ai-sandbox.git cd ai-sandbox/comfyui-universal
-
Install dependencies:
docker-compose build
-
Run ComfyUI:
sudo docker-compose up [-d]
-
Access ComfyUI: Open a web browser and navigate to http://localhost:8188/
-
Load models in correct workflow: Click on "Load" in ComfyUI, select
owl.json
.
models.json
- Defines all model files that need to be loaded.
Property | Description |
---|---|
name |
Filename |
displayName |
Display name |
description |
Short description |
version |
Version |
license |
License |
origin |
URL from where to download |
location |
Location in ComfyUI (use @ for root folder /app/ComfyUI ) |
.env
- Defines settings.
Variable | Description |
---|---|
PROJECT_ROOT |
Defines ComfyUI root folder |
OVERRIDE_MODELS |
Always download models anew |
MODEL_CONFIG_PATH |
Path to models.json |
BEFORE_DEPLOY_CMD |
Command to run before deployment |
AFTER_DEPLOY_CMD |
Command to run after deployment |
TIMEOUT_RETRIES |
Number of retries for downloading model files |
.models
folder - All models are downloaded to the .models
folder.
-
Windows Validation Issue: Validation sometimes fails in Windows.
Solution: Change line endings from CRLF to LF incheck_compatibility.sh
, or setBEFORE_DEPLOY_CMD
to empty in.env
. -
Model Download Issue: After downloading a model, no action occurs.
Solution: Force quit the container usingCTRL+C
twice and start again.
Original Project: ComfyUI is a product of Comfy Org.
Dockerization and Optimization: This project was created by TD99 with contributions from other developers in the open-source community.
Codebase and Dependencies:
NVIDIA Container Toolkit: A product of NVIDIA Corporation.
Docker: A containerization platform developed by Docker Inc.