ComfyUI

ComfyUI

파란크리스마스 2025. 4. 29. 21:29
728x90

출처

python 가상 환경 만들기

[bluesanta@localhost local]$ sudo ln -s /home/bluesanta/Applications/stable-diffusion /usr/local/stable-diffusion
[bluesanta@localhost ~]$ cd /usr/local/stable-diffusion/
[bluesanta@localhost stable-diffusion]$ python3.11 -m venv .venv

python 가상 환경 실행

[bluesanta@localhost stable-diffusion]$ source .venv/bin/activate
(.venv) [bluesanta@localhost stable-diffusion]$

pip 업그레이드

(.venv) [bluesanta@localhost stable-diffusion]$ python -m pip install --upgrade pip

ComfyUI 다운로드

(.venv) [bluesanta@localhost stable-diffusion]$ git clone https://github.com/comfyanonymous/ComfyUI.git

ComfyUI 관련 패키지 설치

(.venv) [bluesanta@localhost stable-diffusion]$ cd ComfyUI/
(.venv) [bluesanta@localhost ComfyUI]$ pip install -r requirements.txt

ComfyUI 실행

(.venv) [bluesanta@localhost ComfyUI]$ python main.py
Checkpoint files will always be loaded safely.
Total VRAM 24090 MB, total RAM 128222 MB
pytorch version: 2.7.0+cu126
Set vram state to: NORMAL_VRAM
Device: cuda:0 NVIDIA GeForce RTX 4090 : cudaMallocAsync
Using pytorch attention
Python version: 3.11.12 (main, Apr 22 2025, 23:29:55) [GCC 11.5.0 20240719 (Red Hat 11.5.0-5)]
ComfyUI version: 0.3.30
****** User settings have been changed to be stored on the server instead of browser storage. ******
****** For multi-user setups add the --multi-user CLI argument to enable multiple user profiles. ******
ComfyUI frontend version: 1.17.11
[Prompt Server] web root: /home/bluesanta/Applications/stable-diffusion/.venv/lib/python3.11/site-packages/comfyui_frontend_package/static

Import times for custom nodes:
   0.0 seconds: /home/bluesanta/Applications/stable-diffusion/ComfyUI/custom_nodes/websocket_image_save.py

Starting server

To see the GUI go to: http://127.0.0.1:8188

ComfyUI Manager 설치

(.venv) [bluesanta@localhost ComfyUI]$ cd custom_nodes
(.venv) [bluesanta@localhost custom_nodes]$ git clone https://github.com/ltdrdata/ComfyUI-Manager.git

stable-diffusion-webui 모델 공유

(.venv) [bluesanta@localhost custom_nodes]$ cd /usr/local/stable-diffusion/ComfyUI/
(.venv) [bluesanta@localhost ComfyUI]$ cp extra_model_paths.yaml.example extra_model_paths.yaml
(.venv) [bluesanta@localhost ComfyUI]$ vi extra_model_paths.yaml
#    base_path: path/to/stable-diffusion-webui/
    base_path: /usr/local/stable-diffusion/stable-diffusion-webui/

ComfyUI 외부접속 허용

(.venv) [bluesanta@localhost ComfyUI]$ python main.py --listen 0.0.0.0

8188 포트 개방

[bluesanta@localhost ~]$ sudo firewall-cmd --permanent --zone=public --add-port=8188/tcp
success
[bluesanta@localhost ~]$ sudo firewall-cmd --reload
success
[bluesanta@localhost ~]$ sudo firewall-cmd --list-ports
3389/tcp 7860/tcp 8188/tcp
728x90