Skip to content

CLI Commands

CommandDescription
mvmctl bootstrapFull setup from scratch: Homebrew deps (macOS), Lima, Firecracker, kernel, rootfs
mvmctl setupCreate Lima VM and install Firecracker assets (requires limactl)
mvmctl setup --recreateStop microVM, rebuild rootfs from upstream squashfs
mvmctl devAuto-bootstrap if needed, drop into Lima dev shell
mvmctl statusShow platform, Lima VM, Firecracker, and microVM status
mvmctl destroyTear down Lima VM and all resources (confirmation required)
mvmctl doctorRun system diagnostics and dependency checks
mvmctl updateCheck for and install mvmctl updates
mvmctl update --checkOnly check for updates, don’t install
CommandDescription
mvmctl startStart the default microVM (headless)
mvmctl start <image>Start a custom image with optional —cpus, —memory, —volume
mvmctl stopStop the running microVM and clean up
mvmctl stop --snapshotCreate a snapshot before stopping (for instant restart)
mvmctl shellOpen a shell in the Lima VM
mvmctl shell --project ~/dirOpen shell and cd into a project directory
mvmctl syncBuild mvmctl from source inside Lima and install to /usr/local/bin/
mvmctl sync --debugDebug build (faster compile, slower runtime)
mvmctl ssh-configPrint an SSH config entry for the Lima VM
CommandDescription
mvmctl build <path>Build from Mvmfile.toml in the given directory
mvmctl build --flake <ref>Build from a Nix flake (local or remote)
mvmctl build --flake <ref> --watchBuild and rebuild on flake.lock changes
mvmctl run --flake <ref>Build from flake and boot a headless Firecracker VM
mvmctl run --template <name>Run from a pre-built template
mvmctl run --config-dir <path>Inject config files onto the config drive
mvmctl run --secrets-dir <path>Inject secret files onto the secrets drive
mvmctl run --volume host:guest:sizeMount a volume into the microVM
CommandDescription
mvmctl snapshot create <name>Snapshot a running VM (pause → snapshot → resume)
mvmctl snapshot delete <name>Remove snapshot files for a VM
CommandDescription
mvmctl template init <name> --localScaffold a new template directory with flake.nix
mvmctl template create <name>Create a single template definition
mvmctl template create-multi <base>Create templates for multiple roles
mvmctl template build <name>Build a template (runs nix build in Lima)
mvmctl template build <name> --forceRebuild even if cached
mvmctl template warm <name>Auto-warm: boot → health wait → snapshot → store
mvmctl template push <name>Push to S3-compatible registry
mvmctl template pull <name>Pull from registry
mvmctl template verify <name>Verify template checksums
mvmctl template listList all templates
mvmctl template info <name>Show template details and revisions
mvmctl template edit <name>Edit template configuration (—cpus, —mem, —flake, etc.)
mvmctl template delete <name>Delete a template
CommandDescription
mvmctl vm ping [name]Health-check running microVMs via vsock
mvmctl vm status [name]Query worker status (--json for JSON)
mvmctl vm inspect <name>Deep-dive inspection (probes, integrations, worker status)
mvmctl vm exec <name> -- <cmd>Run a command inside a running microVM (dev-only)
mvmctl vm diagnose <name>Run layered diagnostics on a VM
mvmctl logs <name>View guest console logs
mvmctl logs <name> --hypervisorView Firecracker hypervisor logs
CommandDescription
mvmctl security statusShow security posture score (--json for JSON)
CommandDescription
mvmctl completions <shell>Generate shell completions (bash, zsh, fish)
VariableDescriptionDefault
MVM_DATA_DIRRoot data directory for templates and builds~/.mvm
MVM_FC_VERSIONFirecracker version (auto-normalized to vMAJOR.MINOR)Latest stable
MVM_FC_ASSET_BASES3 base URL for Firecracker assetsAWS default
MVM_FC_ASSET_ROOTFSOverride rootfs filenameAuto-detected
MVM_FC_ASSET_KERNELOverride kernel filenameAuto-detected
MVM_BUILDER_MODEBuilder transport: auto, vsock, or sshauto
MVM_TEMPLATE_REGISTRYS3 endpoint for template push/pullNone
MVM_SSH_PORTLima SSH local port60022
MVM_PRODUCTIONEnable production mode checksfalse
RUST_LOGLogging level (e.g., debug, mvm=trace)info