Reference
CLI reference
Every command and flag accepted by uncontainer.
uncontainer run
uncontainer run [BOOT FLAGS] -- COMMAND [ARGS...]Boots a guest with a copy of the current worktree, runs the command in /work, returns its exit code and discards the guest.
uncontainer session open
uncontainer session open [BOOT FLAGS]Opens a session for the current worktree, or reuses the running one. Prints the session ID and worktree path, and published ports to stderr.
Boot flags
Accepted by run and session open.
| Flag | Value | Notes |
|---|---|---|
--profile | NAME | Loads a profile from uncontainer.json. Explicit flags override it. |
--distro | debian · alpine · debian:docker | Default debian. |
--cpus | 1–16 | Default 1. |
--memory | 128MiB–4GiB | Whole MiB, for example 512MiB or 1GiB. |
--network | none · full | Default none. Cannot be combined with --allow. |
--allow | HOST:PORT | Repeatable. Replaces the profile’s network policy. |
--publish, --forward | [HOST:]GUEST | Repeatable. Omit HOST for an OS-assigned port. |
--yes | Approves downloading the debian:docker image. | |
--https | [NAME:]GUEST_PORT | run only, once. Serves the app at https://NAME.uncontainer.localhost and copies host edits live. Requires https enable. |
uncontainer https
uncontainer https enable
uncontainer https disable
uncontainer https proxy [--port PORT]enable creates a private CA with mkcert and trusts it for your account after confirmation. On macOS it also installs a user LaunchAgent listening on port 443. disable stops the listener, deletes the keys and removes trust. proxy runs the listener in the foreground on Linux, on port 8443 by default. See the HTTPS guide.
uncontainer session exec
uncontainer session exec -- COMMAND [ARGS...]Runs a command in the current worktree’s session, in /work.
uncontainer session list
uncontainer session list [--json]Shows ID, branch, distro, uptime, host RSS, guest RAM, vCPUs, network policy, published ports and worktree. See JSON output.
uncontainer session close
uncontainer session close [ID]Closes the current worktree’s session, or the given ID from any directory.
uncontainer session prune
uncontainer session prune [--dry-run]Closes sessions whose worktree was removed or replaced. --dry-run lists them without closing.
uncontainer profile list
uncontainer profile list --jsonReads uncontainer.json without starting a guest.
uncontainer cache
uncontainer cache stats [--json]
uncontainer cache cleanstats reports retained bytes, the limit and each snapshot. clean removes all saved caches of the project.
uncontainer update
uncontainer update [--check] [--yes]
uncontainer update cli [--to TAG] [--check] [--yes]
uncontainer update image DISTRO [--to vN] [--check] [--yes]Updates the CLI and cached guest images from the release registry. --check prints the download plan without applying it. --yes applies without prompting and is required without a terminal. DISTRO is debian, alpine or debian:docker; --to vN applies to debian:docker only. See Update.
--version and --help
uncontainer --version
uncontainer session --help--version prints the release tag. --help or -h works at every command level and lists its options and examples.