Run your first VM
The fastest path to a running microVM is microagent run. It pulls an OCI
image, builds a rootfs, boots a VM, runs the command you supply, and tears
down.
microagent run \ --image docker.io/library/ubuntu:24.04 \ --exec "uname -a"Microagent downloads the default kernel for the host backend the first time it needs one.
Run setup commands first
Section titled “Run setup commands first”--setup runs once before --exec. Repeat the flag for multiple commands.
microagent run \ --image docker.io/library/busybox:1.36 \ --setup "mkdir -p /workspace" \ --setup "echo ready > /workspace/status" \ --exec "cat /workspace/status"Use a custom kernel
Section titled “Use a custom kernel”microagent run \ --image docker.io/library/ubuntu:24.04 \ --exec "uname -a" \ --kernel /tmp/ImageManage kernels explicitly with microagent kernel.
What just happened
Section titled “What just happened”- Microagent fetched the OCI image.
- It converted the image into an ext4 rootfs.
- It booted the VM via the host backend (Firecracker or Apple VF).
- The guest init ran
--setupthen--exec. - Microagent collected output, shut the VM down, and removed scratch state.
To keep the workspace around so you can start and stop it on demand, see
Named workspaces and create.