builder/HOOK-REVIEW.md

3.3 KiB

Core prototype: observed package actions

Research dated 2026-11-04, based on the 158-package Core transaction retained at superserv1:/hdd/archipelago/runs/core-iso-01/evidence/. This is the inspected input set for the experimental profile, not a generic approval of future package versions. Full hooks and installed .INSTALL sources are retained in that evidence directory.

Action Prototype treatment
mkinitcpio install hook Suppress through an explicit pacstrap HookDir; generate the complete Core initramfs explicitly, without autodetect
depmod Temporary staging indexes permitted; repeat for the explicit target kernel before final initramfs
glibc locale-gen/iconvconfig/ldconfig Staging outputs; explicit final ldconfig, no inherited host locale selection
GLib schemas/GIO module caches Generated for the single Core package set; the marker overlay and nano fixture add no schema/module inputs
CA trust Distribution certificates only, generated in isolated staging
systemd hwdb/catalog Staging generation; hwdb explicitly regenerated in vendor /usr
systemd sysusers/tmpfiles Disposable staging state; target boot uses standard sysusers/tmpfiles; persistent staging /var is excluded
systemd sysctl/binfmt/reload/modules, dbus reload, sshd restart chroot-aware package adapters skip live actions; target services handle runtime activation
systemd ConditionNeedsUpdate Preserve the distribution trigger; reconcile on target boot
removal-only hooks Not triggered by the fresh Core install or additive nano transaction

Observed scriptlets: archlinux-keyring, bash, ca-certificates-utils, dbus-broker, gnupg, libxcrypt, p11-kit, sudo, systemd, tar. Most perform version-gated upgrade migrations or notices, inapplicable to fresh installation. p11-kit supplies initial user socket enablement. systemd creates temporary staging machine-id/accounts and enables declared base services; machine-id is reset before committing, and per-machine SSH keys are created on target boot. Pacman signing keys/private agent state are not copied into the image.

The first experiment exposed mkinitcpio's automatic root detection in a chroot. Its error did not make pacman fail. This confirms why pacman's exit code alone is insufficient. Later prototypes explicitly defer that hook; required generator commands use fail-fast execution. Full hash-pinned action classification and general PostTransaction result handling remain required before arbitrary package sets or public publication are supported.

The initial prototype accepted only the nano fixture. Repository-backed extensions now retain this reviewed Core hook/scriptlet inventory in the base image under usr/lib/archipelago/hook-policy/. Downloaded archives are checked before package installation; new hook identities or unclassified .INSTALL scripts block the candidate. Standard base hooks retain ALPM trigger semantics. Full-composition library/hwdb/schema/MIME/icon/trust and initramfs finalization runs offline.

Additional inspection on superserv1 (2026-11-04): mc 4.8.33-1, htop 3.5.3-1, tree 2.3.2-1, gpm 1.20.7.r38.ge82d1a6-7, slang 2.3.3-4 contain no .INSTALL, new ALPM hooks or /var//opt payload entries. This is input inspection, not proof of successful extension activation; see the separate VM result report.