11# Experimental mkosi backend
22
3- This is a deliberately small Debian/mkosi implementation of the dstack guest
4- OS. It is an experiment, not yet a replacement for the release Yocto backend.
5- It tracks the Yocto image's confidential-computing, container, storage,
6- network, TPM, SSH, chrony and dstack guest-service capabilities.
3+ This is an experimental Debian/mkosi implementation of the dstack guest OS.
4+ It is not yet a replacement for the release Yocto backend. Its acceptance
5+ target is functional parity with the Yocto image, not merely release archive
6+ compatibility. ` parity.json ` is the machine-checked inventory used by a build.
7+
8+ The backend builds the same dstack services plus the pinned Yocto component
9+ set: Linux 7.1, NVIDIA 595.58.03 (open modules, userspace, firmware, Fabric
10+ Manager and NSCQ), nvattest 2026.06.09 with the OCSP-freshness patch, OpenZFS
11+ 2.4.0 with upstream Linux 6.19--7.1 compatibility backports, Sysbox 0.6.7,
12+ NVIDIA Container Toolkit, nerdctl, CNI plugins and stargz-snapshotter 0.18.2.
713
814## Reproducibility model
915
@@ -25,12 +31,15 @@ checked before compilation.
2531
2632## Build and acceptance
2733
28- Host requirements include mkosi >= 26, systemd tools, a C/Rust kernel and EDK2
29- build toolchain, ` bc ` , ` bison ` , ` flex ` , ` nasm ` , ` iasl ` , OpenSSL/ELF/UUID
30- development headers, ` patch ` , ` pax-utils ` (` lddtree ` ), ` squashfs-tools ` ,
31- ` cryptsetup ` , ` gdisk ` , ` dosfstools ` , ` mtools ` , ` curl ` , ` xz ` , QEMU/KVM and root
32- privileges (or a working user namespace). Full UKI release assembly also needs
33- the pinned ` nitro-tpm-pcr-compute ` described by ` os/image/assemble.sh ` .
34+ Host requirements include mkosi >= 26, systemd tools, C/C++/Go/Rust kernel and
35+ EDK2 build toolchains, ` autoconf ` , ` automake ` , ` libtool ` , ` bc ` , ` bison ` ,
36+ ` flex ` , ` nasm ` , ` iasl ` , and development headers for OpenSSL, ELF, UUID, udev,
37+ aio, attr, blkid, curl, seccomp and tirpc. BTF generation requires ` pahole `
38+ (the ` dwarves ` package). Runtime build tools include ` patch ` ,
39+ ` pax-utils ` (` lddtree ` ), ` squashfs-tools ` , ` cryptsetup ` , ` gdisk ` ,
40+ ` dosfstools ` , ` mtools ` , ` curl ` , ` xz ` , QEMU/KVM and root privileges (or a
41+ working user namespace). Full UKI release assembly also needs the pinned
42+ ` nitro-tpm-pcr-compute ` described by ` os/image/assemble.sh ` .
3443
3544``` sh
3645./os/mkosi/build.sh lint
@@ -42,6 +51,10 @@ qemu-system-x86_64 -machine q35 -m 2G -nographic \
4251 -drive if=virtio,format=raw,file=os/mkosi/build/out/prod/dstack-0.6.0/disk.raw
4352```
4453
54+ On a 16-job development host, a clean production work directory takes about
55+ 17 minutes (measured 16m45s); allow 20--30 minutes with cold compiler and
56+ network caches. ` repro-check ` performs two such builds sequentially.
57+
4558Acceptance means: the static contract passes; a disk with systemd-boot/UKI
4659boots on x86_64 QEMU; ` /proc/config.gz ` contains the checked TDX/SNP, TPM,
4760ACPI, dm-verity/crypt, virtio, container and hardening options; dstack services
@@ -50,8 +63,9 @@ artifact-manifest schema v1 and delegates final assembly to
5063` os/image/assemble.sh ` , exactly like Yocto. Its output contains the same
5164` dstack-0.6.0/ ` directory, bare-metal and UKI tarballs, partitioned combined
5265squashfs/dm-verity image, metadata, measurements, checksums, kernel, initramfs,
53- OVMF and UKI. Package contents differ because this backend uses Debian, but
54- consumers see the same release format and partition labels.
66+ OVMF and UKI. Debian supplies the base userspace while the parity checker
67+ requires the Yocto-visible binaries, services, configuration, kernel modules
68+ and production/development separation before assembly is allowed to proceed.
5569
5670The firmware is not Debian's generic OVMF: ` build-ovmf.sh ` builds the same
5771EDK2 stable-202502 revision and ` pre202505 ` TDX measurement layout selected by
0 commit comments