How to Set Up ComfyUI with Cloud Storage for Portable AI Experiments
ComfyUI is an open-source, node-based interface for assembling reproducible image-generation workflows. It lets you build graphs that connect models, samplers, and utilities, supports custom nodes and model management, runs locally or on a server, and works with both NVIDIA and AMD GPUs.
ComfyUI Installation
First, set up a VM instance with a GPU. You can use CloudRift, but any cloud provider with GPU support will work.
Step 1: Clone ComfyUI
git clone https://github.com/comfyanonymous/ComfyUI.git
cd ComfyUI
Step 2: Create a virtual environment (with uv)
curl -LsSf https://astral.sh/uv/install.sh | sh
source $HOME/.local/bin/env
uv venv
Step 3: Install PyTorch
Pick the right command for your GPU:
# for AMD gpus
uv pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/rocm6.4
# for NVIDIA gpus (cu129 = cuda 12.9)
uv pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu129
Step 4: Install dependencies
uv pip install -r requirements.txt
Step 5: Run ComfyUI
uv run main.py --listen 0.0.0.0
Now UI is available at http://<your-vm-ip-address>:8188.
Download Model Files
For example to set up Flux Krea Dev, download these files and place them in the right subfolders:
Text encoders → models/text_encoders:
clip_l.safetensorst5xxl_fp16.safetensors
VAE → models/vae:
ae.safetensors
Diffusion models → models/diffusion_models:
flux1-krea-dev_fp8_scaled.safetensors

For more examples of model downloads and supported folders, check the ComfyUI examples. They usually explain which folder a model belongs to and whether extra files (like CLIP or VAE) are required.
Use Cloud Storage
Google Drive works surprisingly well for ComfyUI data, especially if you want a simple and free option. For larger or more bandwidth‑intensive workflows, services like Google Cloud Storage or AWS S3 can deliver faster and more reliable transfers — especially when your VM is in the same region as the storage bucket.
Follow my previous guide How to Mount Cloud Storage on a VM (Google Drive, GCS, S3) and mount your Google Drive at ~/gdrive.
Copy your models and custom files:
mkdir gdrive/comfyui
cp -r ComfyUI/models ~/gdrive/comfyui
# user directory contains your workflows
cp -r ComfyUI/user ~/gdrive/comfyui
cp -r ComfyUI/custom_nodes ~/gdrive/comfyui
On a new VM, either use directly from Drive or copy to local disk for faster access:
cp -r gdrive/comfyui ~/work/
Run ComfyUI with ~/work/comfyui as the base directory and keep temp directory on local drive:
uv run main.py --listen 0.0.0.0 --base-directory ~/work/comfyui/ --temp-directory ~/ComfyUI/
You can also enable preview and logs:
uv run main.py --listen 0.0.0.0 --base-directory ~/work/comfyui/ --temp-directory ~/ComfyUI/ --verbose --preview-method auto --log-stdout
You can of course use the Google Drive directory directly:
uv run main.py --listen 0.0.0.0 --base-directory ~/gdrive/comfyui/ --temp-directory ~/ComfyUI/ --verbose --preview-method auto --log-stdout
Unison
If you chose to copy files to local disk for better performance, you can periodically sync changes back to cloud storage. There are many ways to do that and one of them is Unison. Unison can help keep two folders in sync bidirectionally. Unlike one‑way tools, Unison detects changes on both sides, handles conflicts interactively, preserves timestamps/permissions, and supports ignore rules for transient files (like caches or temp/output). Run it on demand or schedule it (cron/systemd) to continuously mirror changes between machines.
unison ~/gdrive/comfyui/ ~/work/comfyui/
For every detected change, Unison will prompt you to choose what to do if change is detected. If there is no conflict it's enough to press Enter to accept the default action. You can also press / to skip given file. You can find a quick introduction to Unison here.
It can be used to sync between two machines as well. If you want to sync your workflows between your VM instance and local machine, you can use Unison over SSH:
unison ssh://user@home_ip//home/user/work/comfyui/ ~/work/comfyui/
Final Notes
- Cloud storage speed depends on your bandwidth and region.
- For heavy workflows, a local SSD usually gives the best performance.
- ComfyUI's modular structure makes sharing and reusing setups between machines simple.
Whether you're experimenting with different models or maintaining consistent workflows across multiple environments, this setup gives you the flexibility to work efficiently while keeping everything portable and backed up.
