Commit Graph
16 Commits
Author SHA1 Message Date
Job79andClaude Opus 5.5 d76d28ef8a Sign local builds with mkosi -f genkey
os / os (push) Failing after 2m14s
It replaces mkosi.crt for local tests, without openssl or a
mkosi.local.conf.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 18:28:04 +00:00
Job79andClaude Opus 5.5 d1c7c55700 Run jobs in our own job image
os / os (push) Failing after 2m42s
mkosi.images/job/ builds an OCI image with git, Node.js 26 and dnf, and
the OS ships it in /usr, so it is signed and updated with the OS.
gitea-runner.service loads it at boot instead of pulling Fedora, and
JavaScript actions work without installing Node.js in each job.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 17:48:04 +00:00
Job79andClaude Opus 5.5 6a32e00431 Docs: sign local builds with a test key in mkosi.local.conf
os / os (push) Failing after 1m34s
mkosi genkey won't replace mkosi.crt, and the key options on the command
line miss the PCR and verity keys. mkosi already pulls in zstd and
qemu-img, so the workflow doesn't install them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 16:07:31 +00:00
Job79andClaude Opus 5.5 0733ff55f3 Rewrite on the layout of agentos
os / os (push) Failing after 29s
Start again from agentos: a read-only, verity-checked /usr with A/B
updates, and a TPM-encrypted btrfs root made at first boot that holds
/etc and /var. On top of that the runner: gitea-runner from gitea.com,
a path unit that starts it once registered, and a drain before update
reboots. Jobs run in plain Fedora on root's podman.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 15:59:36 +00:00
Job79andClaude Opus 5.5 0569bce676 Secure Boot
mkosi signs systemd-boot and the UKI with our own key (mkosi.crt; the private
key is the SECUREBOOT_KEY secret, which the os workflow writes to mkosi.key)
and puts the keys on the ESP. systemd-boot enrolls them at first boot if the
firmware is in setup mode: in Proxmox, an EFI disk without pre-enrolled keys.
Hosts installed before this keep their unsigned systemd-boot (updates don't
replace it), so they boot as before, without Secure Boot.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 22:43:54 +01:00
Job79andClaude Opus 5.5 f3dfbb4f78 Give memory unused for an hour back to the host
damon_reclaim pages out memory that hasn't been touched for an hour, whatever
memory is free, so virtio-balloon free page reporting can return it to the
host. The test VM in the README gets a balloon device.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 22:43:54 +01:00
Job79andClaude Opus 5.5 92a21ae607 Sign updates
The os workflow signs SHA256SUMS with the SIGNING_KEY secret and publishes
SHA256SUMS.gpg next to it. systemd-sysupdate now verifies it (Verify=yes)
against import-pubring.pgp, so hosts only install updates we built.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 22:43:54 +01:00
Job79andClaude Opus 5.5 607987ebbd Build the OS on our own job image
The os workflow now runs on linux, our job image, instead of plain Fedora; it
already has git, so only mkosi is installed. If a change breaks the job image,
build the fix locally.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 22:43:54 +01:00
Job79andClaude Opus 5.5 cd8dfd52f8 Publish updates as a generic package
Each build replaces version "latest" of the generic package git-runner: one
delete and one upload per file, with no release ids or pruning. Updates are no
longer atomic: while a build uploads, runners find no update and retry later.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 16:25:35 +01:00
Job79andClaude Opus 5.5 29ac7278a1 Publish each build as its own release
Gitea serves releases/download/latest/ from the newest published release, so
instead of replacing assets in a fixed "latest" release, each build uploads to
a draft and publishes it, then removes all but the newest 3 releases. The qcow2
is now published on every build, as latest only looks at the newest release.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 16:22:07 +01:00
Job79andClaude Opus 5.5 5bb84ade05 Drop skopeo from the job image
Nothing uses it, and podman doesn't need it; jobs that do can dnf install it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 16:22:07 +01:00
Job79andClaude Opus 5.5 5f2a5c2b23 First-boot setup on the serial console too
The setup asked only on the screen (tty1); it now also asks on the serial console (ttyS0), so a
VM can be set up from a serial terminal or a script. Whichever console is answered first stops
the setup on the other.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01V27snprgiQMRMB6RRDNjCX
2026-11-14 12:21:50 +00:00
Job79andClaude Opus 5.5 b0a49de3e6 Seal /etc: read-only root with /etc and /usr, state on /var
The root filesystem (/etc and /usr) is now one read-only erofs partition behind dm-verity,
updated A/B as a whole, so /etc can no longer drift from the image (stale CA certificates,
frozen Fedora defaults). All state lives on a new /var partition, mounted by /etc/fstab.

What used to be written to /etc at runtime:
- machine ID: from the VM's firmware UUID (systemd.machine_id=firmware); /etc/machine-id is
  empty, so no boot counts as the first.
- root password: gitea-runner-setup writes a shadow file to /var/lib/shadow, which
  etc-shadow.mount puts over /etc/shadow.
- hostname and runner.env: runner.env moves to /var/lib/gitea-runner and holds the runner's
  name; gitea-runner.service sets it as the (transient) hostname, and DHCP no longer does.

Hosts installed before this change must be reinstalled: updates can't change the partition
layout.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01V27snrGfdvwU7pMNBiDpHv
2026-11-14 12:12:10 +01:00
Job79andClaude Opus 5.5 c2ec9ddb29 Smaller image: fewer kernel modules and files, unused services removed, oomd for jobs
- Kernel modules: all but hardware drivers, plus the VM and podman network drivers.
- Removed: System.map, the udev hwdb, and the homed/userdbd/nsresourced units.
- Job image: no translations (Locale=C.UTF-8).
- systemd-oomd kills the job container that runs the VM out of memory.
- gitea-runner waits for first-boot setup instead of restarting every 10s.
- Tighter comments in the sysctl config; Verify=no explained in the transfers.

/usr: 367 -> 307 MB, update download 317 -> 260 MB.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01V27snrGfdvwU7pMNBiDpHv
2026-11-14 11:55:48 +01:00
Job79andClaude Opus 5.5 7b26dd92d1 README: boot the image with qemu; explain the kernel command line
os / os (push) Successful in 3m43s
mkosi vm needs systemd on the host and shows only the serial console,
while the first-boot setup runs on the screen.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-12 23:36:54 +01:00
Job79andClaude Opus 5.5 dfa5d69b44 No repo secrets: unsigned image, updates as release assets, job image built by mkosi
os / os (push) Successful in 3m51s
The workflow's own token can't write packages and repo secrets can't be
set, so: build unsigned, publish the sysupdate files as assets of the
"latest" release, and build the job image with mkosi and ship it in /usr
instead of pushing it to a registry. Partition UUIDs are now part of the
update file names, so updated /usr partitions keep the UUIDs usrhash=
expects.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-12 23:21:42 +01:00