From bc8f069d18c5de3dee04ae303227a255248efc1e Mon Sep 17 00:00:00 2001 From: aur-build Date: Thu, 19 Nov 2026 11:17:27 +0000 Subject: pipeline: replace the devtools chroot with pinned pacman -U provisioning MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The chroot step existed to run mkarchroot/makechrootpkg, whose sudo requirement was the whole reason a build had to run on the hub under root-adjacent rules. The sandbox model makes the chroot redundant: the sandbox boots from a base that already carries the official packages, and step 2 now provisions it with a lease manifest instead — every dependency we publish, pinned to the exact version and digest of the artifact the index serves. The hub re-hashes every blob before staging it, installs with pacman -U (no -Sy, no live resolution, no mirror at build time), and the sandbox's own pacman -Q must confirm the pinned world landed before a build may start. A byte that hashes differently, or a world that drifted, fails closed. The build step is now plain makepkg -c -f: no -s (dependencies arrive installed; resolving at build time is what the pinning model forbids) and no -si (ingest signs). mkarchroot/makechrootpkg are gone from the pipeline and the config; their shims stay as stand-ins for the real devtools so the shim protocol itself remains exercised. The shim pacman grew a real fake installed-database: -U refuses bytes that do not hash to the digest their name claims, -Q reports what landed, so the world check is a test and not a no-op. --- tests/dispatch.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'tests/dispatch.rs') diff --git a/tests/dispatch.rs b/tests/dispatch.rs index 8c0e4ff..5f65b6f 100644 --- a/tests/dispatch.rs +++ b/tests/dispatch.rs @@ -178,13 +178,13 @@ fn a_transient_failure_is_retried_up_to_the_cap() { #[test] fn a_missing_toolchain_is_not_retried() { - // m-14: this used to be the transient test. A missing `makechrootpkg` + // m-14: this used to be the transient test. A missing `makepkg` // surfaces as an `Io` error, and `Io` used to mean "retry" — so a // misconfigured host or a full disk burned every attempt and then went // quiet. It is deterministic: the tool is not going to appear. let (mut env, _fx) = env_with_fixture("plain-make"); let id = queued_build(&env, "plain-make"); - env.cfg.makechrootpkg_bin = "/nonexistent/makechrootpkg-for-test".into(); + env.cfg.makepkg_bin = "/nonexistent/makepkg-for-test".into(); env.cfg.max_transient_attempts = 3; env.cfg.dispatch_tick_secs = 0; let pool = dispatch::Pool::spawn(Arc::new(env.cfg.clone()), env.db.clone()); @@ -231,7 +231,7 @@ fn a_reaped_build_resumes_at_the_next_incomplete_step_with_no_duplicate_work() { pipeline::run(&env.cfg, &env.db, &id).unwrap(), pipeline::Outcome::Failed { .. } )); - let builds_before = aur_build::shims::called_with(&env.cfg.hooks.shim_dir.clone().unwrap(), "makechrootpkg", ""); + let builds_before = aur_build::shims::called_with(&env.cfg.hooks.shim_dir.clone().unwrap(), "makepkg", ""); // The worker "died" at publish: the row is leased with a lease nobody will // extend. A fresh dispatcher reaps it and a worker finishes from the @@ -252,7 +252,7 @@ fn a_reaped_build_resumes_at_the_next_incomplete_step_with_no_duplicate_work() { assert_eq!(state, BuildState::Succeeded, "the resumed build did not finish"); assert_eq!( - aur_build::shims::called_with(&env.cfg.hooks.shim_dir.clone().unwrap(), "makechrootpkg", ""), + aur_build::shims::called_with(&env.cfg.hooks.shim_dir.clone().unwrap(), "makepkg", ""), builds_before, "I5: resuming must not rebuild" ); -- cgit v1.2.3