You are not logged in.
Hi there,
I've switch to UKI and am happy with them. But I'd like to automatically delete the (now useless) initramfs each time the generation of the UKI is done (I'm using mkinitcpio).
Is there a way to automate this?
Thanks!
Offline
This depends highly on how you're building the UKI. If you're using mkinitcpio, you should be able to pass a hook or install script that cleans up the initrd images after the UKI is built and placed where it needs to go.
I use kernel-install with ukify, so I'd want to place the commands to clean up the initrd images in /etc/kernel/install.d/99-clean-initrd.install. I haven't tested this, but that should run after all the other kernel-install plugins run.
Offline
Yeah, I guess that's the way but I can't seem to find the way to run a post-install script with mkinitcpio
Offline
https://wiki.archlinux.org/title/Unifie … reset_file:
Optionally, comment out PRESET_image= to avoid storing a redundant initramfs-*.img file
Offline
https://wiki.archlinux.org/title/Unifie … reset_file:
Unified kernel image#.preset file wrote:Optionally, comment out PRESET_image= to avoid storing a redundant initramfs-*.img file
Damn, it was under my nose....
Thanks!
Offline