You are not logged in.
I need to invoke a hook script automatically every time after pacman updates the kernel and/or initramfs.
(mkinitcpio install hooks are called while it's still in progress and the output file isn't there yet.)
Offline
I may be misunderstanding but what I do is have a hook to detect certain package updates and then sign my kernel and boot media. I have the signing process all set up through sbctl (https://github.com/Foxboron/sbctl) but what I think you're interested in here is the hook itself.
❯ cat /etc/pacman.d/hooks/99-secureboot.hook
[Trigger]
Operation = Install
Operation = Upgrade
Type = Package
Target = linux
Target = fwupd
Target = systemd
Target = linux514-tkg-cacule
Target = edk2-shell
[Action]
Description = Signing Kernel for SecureBoot
When = PostTransaction
Exec = /usr/bin/sbctl sign-all
Depends = sbctlOffline
Where is /etc/initramfs/post-update.d on an Arch with mkinitcpio?
Guess you're used to debian/ubuntu ?
Not sue if they use dracut or something else, but mkinitcpio works differently.
The hook posted by cloverskull looks like a good example, if you need more details man alpm-hooks .
Last edited by Lone_Wolf (2021-09-24 10:24:48)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline