Skip to content

jacksnotes/VidFlowLab-ComfyUI-Bridge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 

Repository files navigation

ComfyUI VidFlowLab Bridge User Guide

English | 中文说明


English Guide

Connect your ComfyUI to VidFlowLab Cloud Platform to unlock remote task scheduling capabilities. We provide two connection methods: Plugin Version (Recommended for normal users) and Worker Version (Recommended for servers/headless mode).

Option 1: Plugin Version (Recommended)

Best for users running ComfyUI on a local computer with a GUI.

📥 Installation

Method A: Install via GitHub URL (ComfyUI Manager)

  1. Open ComfyUI Manager
  2. Click Install via Git URL
  3. Enter repo URL: https://github.com/jacksnotes/VidFlowLab-ComfyUI-Bridge
  4. Restart ComfyUI

Method B: Manual Installation (Recommended)

  1. Download VidFlowLab-ComfyUI-Bridge.zip from GitHub Releases.
  2. Unzip it into your ComfyUI/custom_nodes/ directory (Ensure the folder name is VidFlowLab-ComfyUI-Bridge).
  3. Enter the folder and install dependencies:
pip install -r requirements.txt
  1. Restart ComfyUI.

⚙️ Configuration

  1. Log in to VidFlowLab platform, go to "ComfyUI Bridge" page and generate an API Key.
  2. In ComfyUI canvas, Right Click -> Add Node -> VidFlowLab -> 🔗 Bridge Settings.
  3. Fill in the parameters:
    • api_key: Your API Key (starts with cb_)
    • server_url: wss://api.vidflowlab.com/api/v1/comfyui-bridge/ws/connect
  4. Check save_settings, and trigger a run (Queue Prompt).
  5. Seeing Status: Connected means connection is successful.

Option 2: Worker Standalone Version

Best for headless servers (Linux) or long-running background tasks. It's a standalone Python script, not dependent on ComfyUI's plugin system.

📥 Install Dependencies

Requires Python environment:

pip install websocket-client requests

🚀 Running

Ensure your ComfyUI is already running (e.g., http://127.0.0.1:8188).

Run via Command Line

python bridge_worker.py \
  --api-key cb_YOUR_API_KEY \
  --server wss://api.vidflowlab.com/api/v1/comfyui-bridge/ws/connect \
  --comfyui http://127.0.0.1:8188

Run in Background (Linux/Mac) Using nohup:

nohup python bridge_worker.py \
  --api-key cb_YOUR_API_KEY \
  --server wss://api.vidflowlab.com/api/v1/comfyui-bridge/ws/connect \
  > bridge.log 2>&1 &

Or use screen / tmux.

🛠️ Systemd Service (Production)

Create service file /etc/systemd/system/comfyui-bridge.service:

[Unit]
Description=ComfyUI Bridge Worker
After=network.target

[Service]
Type=simple
User=root
# Change to actual path
WorkingDirectory=/opt/comfyui-bridge-worker
# Change to your API Key
Environment=BRIDGE_API_KEY=cb_YOUR_API_KEY
Environment=BRIDGE_SERVER_URL=wss://api.vidflowlab.com/api/v1/comfyui-bridge/ws/connect
# Change to your ComfyUI URL
Environment=COMFYUI_URL=http://127.0.0.1:8188
ExecStart=/usr/bin/python3 bridge_worker.py
Restart=always
RestartSec=10

[Install]
WantedBy=multi-user.target

Enable Service:

sudo systemctl daemon-reload
sudo systemctl enable comfyui-bridge
sudo systemctl start comfyui-bridge
sudo systemctl status comfyui-bridge

FAQ

Q: Connection status is always Disconnected? A:

  1. Check if API Key is copied correctly.
  2. Check if server_url matches exactly (wss://api.vidflowlab.com/api/v1/comfyui-bridge/ws/connect).
  3. If using Docker, ensure container has internet access.

Q: How to connect remote ComfyUI with Standalone Worker? A: Use --comfyui http://REMOTE_IP:8188 argument. Ensure remote ComfyUI listens on 0.0.0.0 (--listen 0.0.0.0) and firewall ports are open.


中文说明

将你的 ComfyUI 连接到 VidFlowLab 云平台,解锁远程任务调度能力。我们提供两种连接方式:插件版(推荐普通用户)和 Worker 独立版(推荐服务器/无头模式用户)。

方式一:插件版 (推荐)

适合在本地电脑运行 ComfyUI 的用户,直接集成在 ComfyUI 界面中。

📥 安装

方法 A:通过 GitHub URL 安装 (ComfyUI Manager)

  1. 打开 ComfyUI Manager
  2. 点击 Install via Git URL
  3. 输入仓库地址: https://github.com/jacksnotes/VidFlowLab-ComfyUI-Bridge
  4. 重启 ComfyUI

方法 B:手动安装 (推荐)

  1. 从 GitHub Releases 下载 VidFlowLab-ComfyUI-Bridge.zip
  2. 解压到 ComfyUI/custom_nodes/ 目录下(确保文件夹名为 VidFlowLab-ComfyUI-Bridge
  3. 进入文件夹运行依赖安装:
pip install -r requirements.txt
  1. 重启 ComfyUI。

⚙️ 配置

  1. 登录 VidFlowLab 平台,在 "ComfyUI 桥接" 页面生成 API Key
  2. 在 ComfyUI 画布中右键添加节点:VidFlowLab -> 🔗 Bridge Settings
  3. 填入参数:
    • api_key: 你的 API Key (以 cb_ 开头)
    • server_url: wss://api.vidflowlab.com/api/v1/comfyui-bridge/ws/connect
  4. 勾选 save_settings,点击执行一次(Queue Prompt)。
  5. 看到 Status: Connected 即表示连接成功。

方式二:Worker 独立版

适合无图形界面的服务器 (Linux) 或需要长期后台运行的场景。它是独立的 Python 脚本,不依赖 ComfyUI 插件系统,更轻量稳定。

📥 安装依赖

需要 Python环境:

pip install websocket-client requests

🚀 运行

确保你的 ComfyUI 已经在运行(例如 http://127.0.0.1:8188)。

命令行直接运行

python bridge_worker.py \
  --api-key cb_你的API密钥 \
  --server wss://api.vidflowlab.com/api/v1/comfyui-bridge/ws/connect \
  --comfyui http://127.0.0.1:8188

后台运行 (Linux/Mac) 使用 nohup

nohup python bridge_worker.py \
  --api-key cb_你的API密钥 \
  --server wss://api.vidflowlab.com/api/v1/comfyui-bridge/ws/connect \
  > bridge.log 2>&1 &

或者使用 screen / tmux

🛠️ Systemd 服务守护 (生产环境推荐)

创建服务文件 /etc/systemd/system/comfyui-bridge.service:

[Unit]
Description=ComfyUI Bridge Worker
After=network.target

[Service]
Type=simple
User=root
# 修改为实际代码路径
WorkingDirectory=/opt/comfyui-bridge-worker
# 修改为你的 API Key
Environment=BRIDGE_API_KEY=cb_你的密钥
Environment=BRIDGE_SERVER_URL=wss://api.vidflowlab.com/api/v1/comfyui-bridge/ws/connect
# 修改为你的 ComfyUI 地址
Environment=COMFYUI_URL=http://127.0.0.1:8188
ExecStart=/usr/bin/python3 bridge_worker.py
Restart=always
RestartSec=10

[Install]
WantedBy=multi-user.target

启用服务:

sudo systemctl daemon-reload
sudo systemctl enable comfyui-bridge
sudo systemctl start comfyui-bridge
sudo systemctl status comfyui-bridge

常见问题

Q: 连接一直是 Disconnected? A:

  1. 检查 API Key 是否正确复制。
  2. 检查 server_url 是否完全一致 (wss://api.vidflowlab.com/api/v1/comfyui-bridge/ws/connect)。
  3. 如果是 Docker 环境,确保容器能访问互联网。

Q: 独立版如何连接远程 ComfyUI? A: 使用 --comfyui http://远程IP:8188 参数,并确保远程 ComfyUI 启动时加了 --listen 0.0.0.0 参数且防火墙放行。

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors