stable-diffusion-webui-docker/docker-compose.yml

92 lines
2.2 KiB
YAML
Raw Normal View History

x-base_service: &base_service
2022-08-27 13:38:12 +02:00
volumes:
- &v1 ./data:/data
- &v2 ./output:/output
stop_signal: SIGKILL
tty: true
2022-08-27 13:38:12 +02:00
deploy:
resources:
2025-07-07 07:58:25 +02:00
# limits:
# cpus: 8
# memory: 48G
2022-08-27 13:38:12 +02:00
reservations:
2025-07-07 07:58:25 +02:00
# cpus: 4
# memory: 24G
2022-08-27 13:38:12 +02:00
devices:
- driver: nvidia
device_ids: ['0']
2025-07-07 07:58:25 +02:00
capabilities: [compute, utility, gpu]
name: webui-docker
services:
download:
build: ./services/download/
profiles: ["download"]
volumes:
- *v1
auto: &automatic
<<: *base_service
profiles: ["auto"]
build: ./services/AUTOMATIC1111
image: sd-auto:78
2025-07-07 07:58:25 +02:00
ports:
- "${WEBUI_PORT:-7860}:7860"
environment:
2022-12-10 12:06:37 +01:00
- CLI_ARGS=--allow-code --medvram --xformers --enable-insecure-extension-access --api
auto-cpu:
<<: *automatic
profiles: ["auto-cpu"]
deploy: {}
2025-07-07 07:58:25 +02:00
ports:
- "${WEBUI_PORT:-7860}:7860"
environment:
- CLI_ARGS=--no-half --precision full --allow-code --enable-insecure-extension-access --api
comfy: &comfy
<<: *base_service
profiles: ["comfy"]
build: ./services/comfy/
image: sd-comfy:7
2025-07-07 07:58:25 +02:00
volumes:
- ./data/models:/opt/comfyui/models
- ./data/config/comfy/custom_nodes:/opt/comfyui/custom_nodes
- ./output/comfy:/opt/comfyui/output
- ./data/models/configs:/opt/comfyui/user/default/
ports:
- "${COMFYUI_PORT:-7861}:7861"
environment:
2025-07-07 07:58:25 +02:00
- COMFYUI_PATH=/opt/comfyui
- COMFYUI_MODEL_PATH=/opt/comfyui/models
- CLI_ARGS=
2025-07-07 07:58:25 +02:00
# - TORCH_FORCE_NO_WEIGHTS_ONLY_LOAD=1
comfy-cpu:
<<: *comfy
profiles: ["comfy-cpu"]
deploy: {}
2025-07-07 07:58:25 +02:00
ports:
- "${COMFYUI_PORT:-7861}:7861"
environment:
- CLI_ARGS=--cpu
2025-07-07 07:58:25 +02:00
auto-full:
<<: *base_service
profiles: [ "full" ]
build: ./services/AUTOMATIC1111
image: sd-auto:78
environment:
- CLI_ARGS=--allow-code --xformers --enable-insecure-extension-access --api
ports:
- "${WEBUI_PORT:-7860}:7860"
convertor:
<<: *base_service
profiles: [ "convert" ]
build: ./services/convert2safetensors
image: sd-convert
volumes:
- ./data/convert:/opt/convert2safetensors/models