You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Firecracker hosts: package caches, builds, the jailer and snapshots #345
#344 adds the firecracker driver (ADR 0070): each session in a microVM of its own on Linux hosts with KVM, from the same images as Docker, without root. It leaves these for later, each its own pull request:
Package caches. The VMs share no filesystem with the host (Firecracker has no virtio-fs or 9p), so projects that share caches get none there. A project's ext4 disk attached to its VM works for one sandbox at a time; several sandboxes of a project at once need something else, such as a file server over the vsock.
Image builds.allowed_builds is always empty with this driver: building a Dockerfile without Docker takes a builder (BuildKit, say) in a VM.
The jailer. Firecracker runs as the host's user, so a VM escape lands where the runner's token is. A host that runs as root could run each VM through Firecracker's jailer, as a user of its own in a chroot and a cgroup.
Snapshots. Stopping a sandbox shuts its VM down, so a resume starts Claude again. A snapshot would resume it with its programs running, for the VM's memory on disk.
CI that boots VMs. GitHub's x86_64 runners have KVM: run cargo test -p fctl-host boots_a_sandbox -- --ignored there, which only ran by hand on aarch64 (Firecracker nested under QEMU). x86_64 hosts and Ubuntu's AppArmor profile for passt are untried.
Disk. Images share no layers, so each takes its whole size, and the first pull of an image unpacks it in a VM, which takes longer than Docker's.
feat: build and publish the kernel of fctl's Firecracker sandboxes sandbox#12 (the kernel). Its Kernel workflow published ghcr.io/hyperstructure/sandbox-kernel:6.18.59 and :6.18 for amd64 and arm64, after booting the amd64 build in Firecracker. Both pull anonymously, as the driver pulls them, and each holds /vmlinux.
in a new ubuntu vm shows this. so firecracker not ready yet right?
filipe@ubuntuvm:~$ FCTL_SERVER=https://app.fctl.sh fctl host install --token xyz
error: No VM or container runtime is ready on this machine:
apple: Apple container needs macOS 26 on Apple silicon
docker: the docker CLI is not installed
lima: limactl is not installed (install Lima: https://lima-vm.io)
Install one, or pass --driver process to run agents without isolation.
filipe@ubuntuvm:~$
@FilipeNas The Firecracker driver has been in fctl since v0.27.0, but fctl host install uses it only when you pass --driver firecracker: --driver auto picks among Apple's container, Docker and Lima. The error you got named Firecracker only once it was ready, so it didn't say what your VM lacks. On Ubuntu it needs KVM that your user may use, and two packages:
sudo usermod -aG kvm $USER# then log in again
sudo apt install passt e2fsprogs
fctl host install --driver firecracker --token …
Inside a VM, /dev/kvm exists only when the hypervisor that runs it has nested virtualization turned on. fctl host install --driver firecracker checks all of this before it registers anything and says what is missing, as fctl host doctor does.
That pull request makes the error list Firecracker on Linux with what it lacks, and say that it needs --driver firecracker. The rest of this issue's list is still to do.
#426 is merged (67a1dc1). From the next fctl release, fctl host install lists Firecracker on Linux with what it lacks when no driver is ready, and says that it needs --driver firecracker. No release has it yet; CI pins fctl.sh's docs to it, so the CLI page's note about this goes live there. Nothing on this issue's list changes: package caches, image builds, the jailer, snapshots, CI that boots VMs, and disk are all still to do.
The jailer:feat(host): run Firecracker VMs through the jailer on root hosts #434. A host that runs as root runs each VM through Firecracker's jailer, as a user of its own in a chroot and a cgroup. It boots jailed as root in the nested aarch64 lab with both passt versions; its CI is running.
Integration left between them, for whichever merges second: package caches and snapshots (a resumed VM must mount its caches again), and the jailer with each of those (a jailed Firecracker can't reach a cache server's socket that root made, and a snapshot written in the chroot goes with it). Each pull request's description says so.
hyperstructure/sandbox#15 is merged (4e00425), and its Kernel workflow published ghcr.io/hyperstructure/sandbox-kernel:6.18.59-1, the kernel with 9p. No host uses it yet: hosts pull the kernel their fctl release pins, and #430 is what pins this one. With it published, #430's VM tests pass in CI on x86_64 (two sandboxes of a project sharing their caches at once), so #430 is out of draft and ready for review. All six pull requests for this issue (#429 to #434) now pass their checks; #429 goes first, and #432 before #433.
#429 (CI that boots VMs, and Firecracker's network on Ubuntu and on root hosts) is merged as 13199ed, and #434 (the jailer for hosts that run as root) as 3127408, both on main. No release has them yet: the newest is v0.30.1, so hosts get them with the next one. #430, #431 and #432 were stacked on #429 and now target main; I'm bringing them up to date with it, and giving #430 (package caches) and #431 (snapshots) what they need for jailed VMs, since the jailer merged first. #433 stays stacked on #432.
#432 (image builds with BuildKit in a VM of each project's own) is merged as aafb7e3, and #433 (images kept over the images they're built on, with their layers' digests checked) as e743b4a, both on main. No release has them yet (the newest is v0.30.1). Left open: #430 (package caches) and #431 (snapshots), both up to date with main as of the jailer and passing their checks; I'm bringing them up to date with these two merges. A jailed VM saves no state yet; that is #437.
#431 (stopped sandboxes resume where they were) is merged as 62d24e0, on main; no release has it yet (the newest is v0.30.1). A jailed VM saves no state yet (#437). #430 (package caches) is the last of these pull requests still open: it's up to date with main and now serves and mounts a resumed VM's caches again, and its checks pass.
Everything on this list is merged into main, each with its VM tests passing in CI's "Firecracker sandboxes" job on x86_64 (as the runner's user, and as root for the jailer):
#437 (jailed VMs saving no state) is done: #439 is merged as 33f177e, so hosts that run as root save and resume their VMs' state too. No release has it yet (the newest is v0.30.2); hosts get it with the next one. Of the follow-ups listed above, only #438 (a first pull of an image that lies over nothing downloads every layer before a VM unpacks them) is left.
Activity
feat(host): run sessions in Firecracker microVMs on Linux hosts (#344)
fctl-sh commentedon Oct 29, 2026
The Firecracker driver and what it needs are merged:
--driver firecrackerwith the next one, throughfctl self updateor auto-update.ghcr.io/hyperstructure/sandbox-kernel:6.18.59and:6.18for amd64 and arm64, after booting the amd64 build in Firecracker. Both pull anonymously, as the driver pulls them, and each holds/vmlinux.What this issue lists is still to do.
FilipeNas commentedon Nov 5, 2026
in a new ubuntu vm shows this. so firecracker not ready yet right?
fctl-sh commentedon Nov 6, 2026
@FilipeNas The Firecracker driver has been in fctl since v0.27.0, but
fctl host installuses it only when you pass--driver firecracker:--driver autopicks among Apple's container, Docker and Lima. The error you got named Firecracker only once it was ready, so it didn't say what your VM lacks. On Ubuntu it needs KVM that your user may use, and two packages:Inside a VM,
/dev/kvmexists only when the hypervisor that runs it has nested virtualization turned on.fctl host install --driver firecrackerchecks all of this before it registers anything and says what is missing, asfctl host doctordoes.That pull request makes the error list Firecracker on Linux with what it lacks, and say that it needs
--driver firecracker. The rest of this issue's list is still to do.fix(cli): say what Firecracker lacks when no driver is ready (#426)
fctl-sh commentedon Nov 6, 2026
#426 is merged (67a1dc1). From the next fctl release,
fctl host installlists Firecracker on Linux with what it lacks when no driver is ready, and says that it needs--driver firecracker. No release has it yet; CI pins fctl.sh's docs to it, so the CLI page's note about this goes live there. Nothing on this issue's list changes: package caches, image builds, the jailer, snapshots, CI that boots VMs, and disk are all still to do.feat: give the Firecracker kernel 9p, for fctl's package caches
fctl-sh commentedon Nov 6, 2026
Each item on this list now has a pull request, all open and none merged yet. They're stacked on #429, which the others need for CI that boots VMs:
accept, systemd-resolved's stub as the only nameserver) and that passt couldn't write its pid as root; fix(host): give Firecracker VMs a network on Ubuntu, and boot them in CI #429 fixes all of these. CI is green.sandbox-kernel:6.18.59-1first, and feat(host): share package caches with Firecracker sandboxes #430's VM tests fail in CI until then.FROMit) keeps only its own layers, over that image's filesystem; the unpacking VM checks each layer's digest. CI is green. Left for later: streaming a first pull's layers into the VM as they download.Integration left between them, for whichever merges second: package caches and snapshots (a resumed VM must mount its caches again), and the jailer with each of those (a jailed Firecracker can't reach a cache server's socket that root made, and a snapshot written in the chroot goes with it). Each pull request's description says so.
feat: give the Firecracker kernel 9p, for fctl's package caches (#15)
fctl-sh commentedon Nov 6, 2026
hyperstructure/sandbox#15 is merged (4e00425), and its Kernel workflow published
ghcr.io/hyperstructure/sandbox-kernel:6.18.59-1, the kernel with 9p. No host uses it yet: hosts pull the kernel their fctl release pins, and #430 is what pins this one. With it published, #430's VM tests pass in CI on x86_64 (two sandboxes of a project sharing their caches at once), so #430 is out of draft and ready for review. All six pull requests for this issue (#429 to #434) now pass their checks; #429 goes first, and #432 before #433.fix(host): give Firecracker VMs a network on Ubuntu, and boot them in…
feat(host): run Firecracker VMs through the jailer on root hosts (#434)
fctl-sh commentedon Nov 6, 2026
#429 (CI that boots VMs, and Firecracker's network on Ubuntu and on root hosts) is merged as 13199ed, and #434 (the jailer for hosts that run as root) as 3127408, both on main. No release has them yet: the newest is v0.30.1, so hosts get them with the next one. #430, #431 and #432 were stacked on #429 and now target main; I'm bringing them up to date with it, and giving #430 (package caches) and #431 (snapshots) what they need for jailed VMs, since the jailer merged first. #433 stays stacked on #432.
feat(host): build projects' images with BuildKit in Firecracker VMs (#…
feat(host): keep Firecracker images over the images they're built on (#…
fctl-sh commentedon Nov 6, 2026
#432 (image builds with BuildKit in a VM of each project's own) is merged as aafb7e3, and #433 (images kept over the images they're built on, with their layers' digests checked) as e743b4a, both on main. No release has them yet (the newest is v0.30.1). Left open: #430 (package caches) and #431 (snapshots), both up to date with main as of the jailer and passing their checks; I'm bringing them up to date with these two merges. A jailed VM saves no state yet; that is #437.
fctl-sh commentedon Nov 7, 2026
#431 (stopped sandboxes resume where they were) is merged as 62d24e0, on main; no release has it yet (the newest is v0.30.1). A jailed VM saves no state yet (#437). #430 (package caches) is the last of these pull requests still open: it's up to date with main and now serves and mounts a resumed VM's caches again, and its checks pass.
fctl-sh commentedon Nov 7, 2026
Everything on this list is merged into main, each with its VM tests passing in CI's "Firecracker sandboxes" job on x86_64 (as the runner's user, and as root for the jailer):
sandbox-kernel:6.18.59-1. A 9P server over the vsock, so several sandboxes of a project share their caches at once.No release has these yet (the newest is v0.30.1): Linux hosts get them with the next one. Left for later, in their own issues:
fctl-sh commentedon Nov 7, 2026
#437 (jailed VMs saving no state) is done: #439 is merged as 33f177e, so hosts that run as root save and resume their VMs' state too. No release has it yet (the newest is v0.30.2); hosts get it with the next one. Of the follow-ups listed above, only #438 (a first pull of an image that lies over nothing downloads every layer before a VM unpacks them) is left.