新增通用文件上传节点

This commit is contained in:
2025-09-12 18:55:30 +08:00
parent 029d41a327
commit 64cb10c369
6 changed files with 51 additions and 31 deletions

View File

@@ -26,7 +26,7 @@ image = (
.run_commands("comfy node install https://github.com/Kosinkadink/ComfyUI-VideoHelperSuite.git")
.run_commands("comfy node install https://github.com/WASasquatch/was-node-suite-comfyui.git")
.run_commands("comfy node install https://github.com/cubiq/ComfyUI_essentials.git")
.add_local_dir(local_path=r'/Users/charon/Desktop/ComfyUI-CustomNode',
.add_local_dir(local_path=r'D:\code\ComfyUI-CustomNode',
remote_path='/root/comfy/ComfyUI/custom_nodes',
copy=True
)
@@ -37,7 +37,7 @@ image = (
.run_commands("rm -rf /root/comfy/ComfyUI/input&&ln -s /models/input /root/comfy/ComfyUI/input")
.run_commands("rm -rf /root/comfy/ComfyUI/output&&ln -s /models/output /root/comfy/ComfyUI/output")
)
app = modal.App(image=image, name='comfyui-video-agent')
app = modal.App(image=image, name='cf-video-api')
custom_secret = modal.Secret.from_name("comfyui-custom-secret", environment_name="dev")
vol = modal.Volume.from_name("comfy_model", environment_name="dev", create_if_missing=True)
@@ -55,9 +55,9 @@ vol = modal.Volume.from_name("comfy_model", environment_name="dev", create_if_mi
@modal.concurrent(
max_inputs=10
)
@modal.web_server(8000, startup_timeout=600, label='image-video-agent-1')
@modal.web_server(8000, startup_timeout=120, label='image-video-agent-1')
def ui_1():
process = subprocess.Popen("comfy launch -- --cpu --listen 0.0.0.0 --port 8000", shell=True)
subprocess.Popen("comfy launch -- --cpu --listen 0.0.0.0 --port 8000", shell=True)
@app.function(
@@ -73,6 +73,6 @@ def ui_1():
@modal.concurrent(
max_inputs=10
)
@modal.web_server(8000, startup_timeout=600, label='image-video-agent-2')
@modal.web_server(8000, startup_timeout=120, label='image-video-agent-2')
def ui_2():
subprocess.Popen("comfy launch -- --cpu --listen 0.0.0.0 --port 8000", shell=True)