Disk usage and cleanup
What local sandboxes keep on disk and how the SDK keeps it bounded.
What local sandboxes keep on disk and how the SDK keeps it bounded.
Images, VM disks and logs live under ~/.cua (CUA_HOME moves them).
cua cache du # usage per category, budget, free space
cua sb ls # SIZE column (--no-size skips it)cua sb command or the daemon deletes them 10 minutes
later./tmp
logs when cua installed Lume).cua do screenshot without --save go to
~/.cua/screenshots; the newest 20 are kept.cua cache prune --dry-run # what would go
cua cache prune # down to the budget
cua cache prune --all # every unused cache entry
cua sb rm my-box -f # a sandbox and all its diskscua cache config --budget 50G --min-free 10G{
"budget": "50G",
"min_free": "10G",
"warn_free": "20G",
"orphan_reap_minutes": 10,
"auto_gc": true
}The environment wins: CUA_CACHE_BUDGET (auto, off or a size),
CUA_DISK_MIN_FREE (default 5G), CUA_DISK_WARN_FREE (20G),
CUA_ORPHAN_REAP_MINUTES (10), CUA_CACHE_AUTO_GC (0 turns it off).
A pull, build or VM create that would leave less than CUA_DISK_MIN_FREE
fails before writing anything: CuaError.InsufficientDisk in the SDKs, exit
code 7 in the CLI.
cua: insufficient disk: not enough disk space to pull ghcr.io/trycua/linux:24.04:
it needs about 3.2 GiB and cua keeps 5.0 GiB free, but only 6.1 GiB is available
on /Users/me/.cua/images (run `cua cache prune` to free space, or lower
CUA_DISK_MIN_FREE)Kept until you remove them; cua-bench warns past 10 GiB
(CUA_BENCH_WARN_SIZE). Keep fewer with cb run ... --keep-runs 20 or
cb prune --runs --keep 20.