Skip to content

Commit 910d3f0

Browse files
authored
feat(vm): boot sandboxes from ext4 root disks (#1263)
* feat(vm): boot sandboxes from ext4 root disks * feat(vm): boot sandboxes with writable overlay disk * fix(sandbox): improve sandbox provisioning behavior * fix(vm): repair sandbox image provisioning * fix(vm): clean up rebase fallout * perf(vm): cache empty overlay images * perf(vm): skip repeated sandbox ownership repair * fix(vm): address lifecycle review issues * fix(vm): repair gateway vm startup * wip
1 parent b61a98d commit 910d3f0

32 files changed

Lines changed: 4491 additions & 770 deletions

‎.github/workflows/driver-vm-linux.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ jobs:
162162
- name: Verify embedded driver inputs
163163
run: |
164164
set -euo pipefail
165-
for file in libkrun.so.zst libkrunfw.so.5.zst gvproxy.zst openshell-sandbox.zst; do
165+
for file in libkrun.so.zst libkrunfw.so.5.zst gvproxy.zst umoci.zst openshell-sandbox.zst; do
166166
test -s "target/vm-runtime-compressed/${file}"
167167
done
168168

‎.github/workflows/driver-vm-macos.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ jobs:
199199
- name: Verify embedded driver inputs
200200
run: |
201201
set -euo pipefail
202-
for file in libkrun.dylib.zst libkrunfw.5.dylib.zst gvproxy.zst openshell-sandbox.zst; do
202+
for file in libkrun.dylib.zst libkrunfw.5.dylib.zst gvproxy.zst umoci.zst openshell-sandbox.zst; do
203203
test -s "target/vm-runtime-compressed-macos/${file}"
204204
done
205205

‎.github/workflows/release-vm-kernel.yml‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -237,9 +237,9 @@ jobs:
237237
238238
### Kernel Runtime Artifacts
239239
240-
Pre-built kernel runtime (libkrunfw + libkrun + gvproxy) for embedding into
241-
the `openshell-driver-vm` binary. These are rebuilt on demand when the kernel
242-
config or pinned dependency versions change.
240+
Pre-built kernel runtime (libkrunfw + libkrun + gvproxy + umoci) for embedding
241+
into the `openshell-driver-vm` binary. These are rebuilt on demand when the
242+
kernel config or pinned dependency versions change.
243243
244244
| Platform | Artifact |
245245
|----------|----------|

‎.markdownlint-cli2.jsonc‎

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,24 @@
11
{
22
"globs": [
3-
"**/*.md",
4-
"**/*.mdx"
3+
"*.md",
4+
"architecture/**/*.md",
5+
"crates/**/*.md",
6+
"deploy/**/*.md",
7+
"docs/**/*.md",
8+
"docs/**/*.mdx",
9+
"e2e/**/*.md",
10+
"examples/**/*.md",
11+
"rfc/**/*.md"
512
],
6-
"gitignore": true,
13+
"gitignore": false,
714
"ignores": [
815
".agents/**",
916
".claude/**",
1017
".opencode/**",
1118
".github/**",
19+
"**/node_modules/**",
20+
"target/**",
21+
".pytest_cache/**",
1222
"THIRD-PARTY-NOTICES/**",
1323
"CLAUDE.md",
1424
// Man page sources use pandoc markdown with multiple H1 sections

‎architecture/compute-runtimes.md‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,20 @@ Each runtime receives a sandbox spec from the gateway and is responsible for:
1616
- Reporting lifecycle and platform events back to the gateway.
1717
- Cleaning up runtime-owned resources.
1818

19+
Drivers own runtime-specific platform event interpretation. When an event should
20+
drive client provisioning UI, the driver attaches the shared
21+
`openshell.progress.*` metadata defined in `openshell-core` instead of requiring
22+
clients to parse Kubernetes reasons, VM cache states, or other driver-local
23+
reason strings.
24+
1925
## Runtime Summary
2026

2127
| Runtime | Best fit | Sandbox boundary | Notes |
2228
|---|---|---|---|
2329
| Docker | Local development with Docker available. | Container plus nested sandbox namespace. | Uses host networking so loopback gateway endpoints work from the supervisor. |
2430
| Podman | Rootless or single-machine deployments. | Container plus nested sandbox namespace. | Uses the Podman REST API, OCI image volumes, and CDI GPU devices when available. |
2531
| Kubernetes | Cluster deployment through Helm. | Pod plus nested sandbox namespace. | Uses Kubernetes API objects, service accounts, secrets, PVC-backed workspace storage, and GPU resources. |
26-
| VM | Experimental microVM isolation. | Per-sandbox libkrun VM. | Gateway spawns `openshell-driver-vm` as a subprocess over a private, state-local Unix socket. |
32+
| VM | Experimental microVM isolation. | Per-sandbox libkrun VM. | Gateway spawns `openshell-driver-vm` as a subprocess over a private, state-local Unix socket. The VM driver boots a cached bootstrap `rootfs.ext4`, prepares requested OCI images inside a bootstrap VM with `umoci`, attaches the prepared image disk read-only, and gives each sandbox a writable `overlay.ext4` for merged-root changes and runtime material. |
2733

2834
Per-sandbox CPU and memory values currently enter the driver layer through
2935
template resource limits. Docker and Podman apply them as runtime limits.

0 commit comments

Comments
 (0)