feat(ci-runners): run the deploy runner in a Kata microVM (staged) #79

Merged
sirius merged 1 commit from wt/t_8aa4af50-kata into master 2026-11-27 07:09:04 +00:00
Owner

Stage 1 of card t_8aa4af50 after the measured dead end in #74: enforce: baseline is unreachable by any container runtime (sysbox/gVisor/Kata all need SYS_ADMIN+NET_ADMIN in the pod spec, which baseline forbids). This converts ONE runner to Kata so privileged: true means microVM root instead of rpi host root.

  • RuntimeClass kata-qemu (rpi containerd handler via /etc/containerd/conf.d/50-kata.toml, kata-static 4.4.0)
  • forgejo-runner-deploy-arm64 only: loop-backed ext4 data-root (overlay2 instead of vfs), binfmt registration for the amd64 cross build, runner waits on /var/run/dind-ready
  • amd64/shared-arm64 runners untouched; ci-runners stays enforce: privileged and the docs say so plainly

Proved with a real deploy-arm64 run before merge.

Stage 1 of card t_8aa4af50 after the measured dead end in #74: `enforce: baseline` is unreachable by any container runtime (sysbox/gVisor/Kata all need SYS_ADMIN+NET_ADMIN in the pod spec, which baseline forbids). This converts ONE runner to Kata so `privileged: true` means microVM root instead of rpi host root. - `RuntimeClass` `kata-qemu` (rpi containerd handler via `/etc/containerd/conf.d/50-kata.toml`, kata-static 4.4.0) - `forgejo-runner-deploy-arm64` only: loop-backed ext4 data-root (overlay2 instead of vfs), binfmt registration for the amd64 cross build, runner waits on `/var/run/dind-ready` - amd64/shared-arm64 runners untouched; `ci-runners` stays `enforce: privileged` and the docs say so plainly Proved with a real `deploy-arm64` run before merge.
The CI capsule cannot enforce PSA baseline: every nested dockerd needs
SYS_ADMIN+NET_ADMIN in the pod spec and baseline forbids exactly those, which
sysbox, gVisor and Kata all reproduce (measured on both arches, card
t_8aa4af50). What a runtime CAN change is what privileged:true means.

Stage 1, one runner: forgejo-runner-deploy-arm64 (rpi) gets
runtimeClassName: kata-qemu, so its privileged dind and job containers run
inside a QEMU/KVM microVM instead of on rpi's host namespaces. The amd64 and
shared arm64 runners stay on privileged dind under runc, untouched.

Kata-specific plumbing in the same Deployment:
- loop-backed ext4 data-root (16GiB image on the existing claim) because
  overlayfs refuses virtiofs and Docker would silently fall back to vfs;
- binfmt_misc + tonistiigi/binfmt --install amd64 on every start, because the
  guest kernel has no qemu handlers and deploy-site.yml cross-builds amd64;
- the runner waits for /var/run/dind-ready (touched after both are set up).

RuntimeClass kata-qemu is cluster-scoped; the containerd handler lives on rpi
only (/etc/containerd/conf.d/50-kata.toml, kata-static 4.4.0). Rollback is one
field. docs/pod-security.md records the measurement and states plainly that the
namespace stays enforce: privileged.
sirius merged commit e5a0460e53 into master 2026-11-27 07:09:04 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
sirius/homek8s!79
No description provided.