Network Volumes for Custom Models with ComfyUI Serverless"
Hey everyone, I'm trying to understand network volumes with RunPod serverless. If I create a ComfyUI serverless endpoint with the default worker image and attach a network volume, can I then launch a regular ComfyUI pod using that same volume to add my custom models and workflows? And will those custom models then be accessible when my serverless endpoint runs? Basically trying to extend the default image without modifying it.
50 Replies
Yes, you can use the same network volume for your pods or serverless endpoints.
One thing to note is that on your pod the network volume will be mounted on the /workspace directory, while on your serverless endpoint it will be mounted on the /runpod-volume directory
So for using your network volume in your serverless endpoint with ComfyUI you'll likely need to create a symlink between the network volume and your serverless instance. Here's a discussion about this: https://www.answeroverflow.com/m/1249796140283727872
And an example: https://github.com/ashleykleynhans/runpod-worker-comfyui/blob/main/start.sh#L5-L7
@neural-soupe ah ok thanks. So for the symlink i would have to create own image of the worker, is there way without maybe creating own worker
Yeah, you'd need to write your own handler function and build a Docker image for it. What image/container are you currently deploying as serverless?
@neural-soupe I just deployed the "timpietruskyblibla/runpod-worker-comfy:3.4.0-flux1-dev" image for quickstart
i would like to just using that image in best case and just add my custom stuff i need like models and loras
but when i open the storage with a template there is nothing like no file but the endpoint is working
I think you'll have to build your own version of the https://github.com/runpod-workers/worker-comfyui worker, where you either download your models in the Dockerfile (https://github.com/runpod-workers/worker-comfyui/blob/main/Dockerfile) or create the symlink for your network volume in the start.sh (https://github.com/runpod-workers/worker-comfyui/blob/main/src/start.sh) script, like the example I shared previously.
So you'll need to download the code for the https://github.com/runpod-workers/worker-comfyui, make the changes you need (either in the Dockerfile or start.sh), re-build and push the image to your own Docker repository, and then use that image for your serverless endpoint
GitHub
GitHub - runpod-workers/worker-comfyui: ComfyUI as a serverless API...
ComfyUI as a serverless API on RunPod. Contribute to runpod-workers/worker-comfyui development by creating an account on GitHub.
GitHub
worker-comfyui/Dockerfile at main · runpod-workers/worker-comfyui
ComfyUI as a serverless API on RunPod. Contribute to runpod-workers/worker-comfyui development by creating an account on GitHub.
GitHub
worker-comfyui/src/start.sh at main · runpod-workers/worker-comfyui
ComfyUI as a serverless API on RunPod. Contribute to runpod-workers/worker-comfyui development by creating an account on GitHub.
@neural-soupe I forked the project and tried deploying using the runpod github intergration, it build it but when it does the testing than i get error, u know more about that?
Unknown User•5mo ago
Message Not Public
Sign In & Join Server To View
@Jason actually now I am getting build failed
Unknown User•5mo ago
Message Not Public
Sign In & Join Server To View
@maverickdoge
Escalated To Zendesk
The thread has been escalated to Zendesk!
Unknown User•5mo ago
Message Not Public
Sign In & Join Server To View
so i didn't add anythig just forked the https://github.com/runpod-workers/worker-comfyui and and tried deploying it
GitHub
GitHub - runpod-workers/worker-comfyui: ComfyUI as a serverless API...
ComfyUI as a serverless API on RunPod. Contribute to runpod-workers/worker-comfyui development by creating an account on GitHub.
I dont wanna create a ticket i tried before and no one responds
Unknown User•5mo ago
Message Not Public
Sign In & Join Server To View
yes I will try
now the build went through but these tests are failing

exactly like i had yesterday
Unknown User•5mo ago
Message Not Public
Sign In & Join Server To View
thanks for that
Unknown User•5mo ago
Message Not Public
Sign In & Join Server To View
Yes, that actually worked — the build is definitely completing now.
I’ve also added the symlink, which you can see here: https://github.com/ImamJanjua/worker-comfyui/blob/main/src/start.sh
I tried running some workflows, but as you can see in the logs, it's failing because it can't find the models.
It looks like it's trying to search in /runpod-volume/models/unet/, which I don't think is correct. Shouldn't it be searching in the workspace folders instead?
Unknown User•5mo ago
Message Not Public
Sign In & Join Server To View
So u are saying the symlink as mentioned at the top of the chat is not actually needed?
Unknown User•5mo ago
Message Not Public
Sign In & Join Server To View
In my network storage I have both so storing models in /workspace and in root. But as u can see in the logs its kinda of trying to access somethig like /runpod-volume/models/unet/ which would not work since it has to atleast go to the comfyUI folder so /runpod-volume/models/unet/...
@neural-soupe only told me about adding the symlink but maybe something else need to changed or added too
Unknown User•5mo ago
Message Not Public
Sign In & Join Server To View
I think its maybe because of that file actully: https://github.com/ImamJanjua/worker-comfyui/blob/main/src/extra_model_paths.yaml
GitHub
worker-comfyui/src/extra_model_paths.yaml at main · ImamJanjua/wor...
ComfyUI as a serverless API on RunPod. Contribute to ImamJanjua/worker-comfyui development by creating an account on GitHub.
u mean on network-storage i just have to create a pods of comfyui then on /workspace/comfyui copy to /runpods-volume/comfyui
right?? then i have to add this network-storage in serverless ?
if yes then on serverless which template i have to install
@everyone
Unknown User•4mo ago
Message Not Public
Sign In & Join Server To View
then bro how i have to put model in /runpod-volume
Unknown User•4mo ago
Message Not Public
Sign In & Join Server To View
in serverless if i attached storage and install it endpoint like comfy then its not show any data on /runpod-volume
Unknown User•4mo ago
Message Not Public
Sign In & Join Server To View
i mean comfyui serverless
if i do then in /runpod-volume still blank in networjk storage
i saying about it
Unknown User•4mo ago
Message Not Public
Sign In & Join Server To View
what you r exact mean i not understand yet bro
Unknown User•4mo ago
Message Not Public
Sign In & Join Server To View
i not using any docker
1. I have created network storage exampel "myapi"
2. then i create a pods on my network storage "myapi"
3. i have used in pods template comfyui
4. after it i stop and create serverless endpoint by template comfyui with attechent storage "myaoi"
how i have to put my model and where
@everyone please help regrading this issue i find solution from approx 1 month
Unknown User•4mo ago
Message Not Public
Sign In & Join Server To View
runpod/worker-comfyui:5.0.4-base
Unknown User•4mo ago
Message Not Public
Sign In & Join Server To View
i want to setup custom model
Unknown User•4mo ago
Message Not Public
Sign In & Join Server To View
Populate the Volume with Models:
Use one of the methods described in the RunPod guide (e.g., temporary Pod + wget, direct upload) to place your model files into the correct ComfyUI directory structure within the volume. The root of the volume corresponds to /workspace inside the container.
Example structure inside the Network Volume:
/models/checkpoints/your_model.safetensors
/models/loras/your_lora.pt
/models/vae/your_vae.safetensors
Important: Ensure models are placed in the correct subdirectories (e.g., checkpoints in models/checkpoints, LoRAs in models/loras).
where i have to put model?
/runpod-volume/comfyui/model or /workspaace/comfyui/model?
Unknown User•4mo ago
Message Not Public
Sign In & Join Server To View
for endpoint which template have to use?
Unknown User•4mo ago
Message Not Public
Sign In & Join Server To View
/workspace/models/ or /workspace/comfyui/models/?
Unknown User•4mo ago
Message Not Public
Sign In & Join Server To View