Start
Concepts
Four ideas explain everything Jasmine does: templates, restores, the lifecycle, and the walls between sandboxes.
Templates
A template is an OCI image that has already been booted once and frozen. Jasmine unpacks the image to a journal-less ext4 disk, boots it in a microVM with its tiny agent as PID 1, warms the page cache with the image's binaries, then snapshots memory and CPU state.
Restore, don't boot
Creating a sandbox never boots a kernel. Jasmine makes an XFS reflink of the template's disk (copy-on-write, constant time whatever the image size), maps the snapshot's memory lazily so pages load only when touched, and resumes the vCPUs. Each restore gets a fresh clock and fresh entropy, so sandboxes from one snapshot never share random numbers.
image ──build──▶ template ──restore──▶ sandbox ──exec / files──▶ …
▲ │
└──── snapshot ◀─────┤
├── pause ⇄ resume
└── deleteLifecycle
- Running: commands and file operations go over virtio-vsock to the agent, as raw framed bytes.
- Paused: dirty memory is written to disk and the VM stops. No CPU is used. Any call resumes it.
- Snapshot: memory, disk and processes become a new template; start as many copies as you like.
- Deleted: the VM is killed, its disk freed and its network slot recycled.
Isolation
Every sandbox is a Firecracker microVM with its own kernel, in its own network namespace. Outbound internet works through NAT, over IPv4 and IPv6. The cloud metadata endpoint, the host's own services and other sandboxes are blocked by firewall rules, and an end-to-end test checks each of those on every push.
Keys and labels
Give a sandbox a unique key (say, a conversation ID) to find it again, and labels to group sandboxes. Both work as filters on GET /v1/sandboxes.