From 157c078e52fee6c37ff20093189ae7ad7cd223cb Mon Sep 17 00:00:00 2001 From: aur-build Date: Wed, 18 Nov 2026 10:26:15 +0000 Subject: the real chroot caught what no shim test could: mkarchroot has no -N flag MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Ran the gated tier as far as this host allows, with real devtools, real root and real network, and it paid for itself immediately. `mkarchroot` has no `-N` option. The pipeline was calling `mkarchroot -N `; the shim ignored the unknown flag, so every test passed, and the real tool answered with a usage error. The first real chroot build would have died on its first step in a code path the shim harness structurally cannot exercise. The seed's package list is now configuration (`mkarchroot_args`, default `base`) and the call follows the real usage: `mkarchroot `. What else the attempt verified, with the real binaries rather than the shims: a generated GPG key detached-signed the artifact the pipeline produced and `gpg --verify` reported a good signature; real `repo-add -s -k` built and signed a pacman database over it, and that signature verified too. So "both the packages and the .db are signed" now rests on real crypto. Where it stops: `mkarchroot base` downloaded and installed the base set into the chroot (437 MB, 14 packages, install scripts ran) and then failed in devtools' init stage with `Failed to parse --bind(-ro)= argument` from systemd-nspawn 262 inside an unprivileged container. DECISIONS.md records exactly what was run, what passed, what failed and why, and what therefore remains modelled rather than crossed — a silent skip would have hidden all of the above, including the flag bug. Also fixes the I9 test's expectation: a refused build is an `Outcome::Failed` at the `collect` step, not an `Err` from the runner, which is the correct shape (the build failed closed and said why) and the test now asserts the step name. 171 tests pass, clippy clean. --- src/config.rs | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/config.rs') diff --git a/src/config.rs b/src/config.rs index 7effa53..9226622 100644 --- a/src/config.rs +++ b/src/config.rs @@ -37,6 +37,13 @@ pub struct Config { pub makechrootpkg_bin: String, /// Path to mkarchroot. pub mkarchroot_bin: String, + /// Package list handed to `mkarchroot` after the working directory, i.e. + /// what goes into the warm root. The default is the real devtools usage + /// (`mkarchroot base`); there is no `-N` flag on the real tool, so + /// hardcoding one would make the first real-chroot run fail on its first + /// step. Kept configurable because a site may want a smaller seed. + #[serde(default = "default_mkarchroot_args")] + pub mkarchroot_args: Vec, /// Path to repo-add. pub repo_add_bin: String, /// Path to gpg. @@ -94,6 +101,7 @@ impl Default for Config { makepkg_bin: "makepkg".into(), makechrootpkg_bin: "makechrootpkg".into(), mkarchroot_bin: "mkarchroot".into(), + mkarchroot_args: default_mkarchroot_args(), repo_add_bin: "repo-add".into(), gpg_bin: "gpg".into(), build_user: String::new(), @@ -250,6 +258,10 @@ impl Config { } /// Filesystem-safe slug for a URL, used in cache filenames. +fn default_mkarchroot_args() -> Vec { + vec!["base".to_string()] +} + pub fn slug(url: &str) -> String { url.chars() .map(|c| { -- cgit v1.2.3