diff options
-rw-r--r-- | .SRCINFO | 3 | ||||
-rw-r--r-- | 55-efi-key.hook | 3 | ||||
-rw-r--r-- | 90-dracut-install.hook | 7 | ||||
-rw-r--r-- | PKGBUILD | 3 | ||||
-rw-r--r-- | dracut-sb.install | 16 |
5 files changed, 21 insertions, 11 deletions
@@ -1,7 +1,8 @@ pkgbase = dracut-sb pkgdesc = dracut secure boot setup using efistub pkgver = 1.0.1 - pkgrel = 1 + pkgrel = 2 + install = dracut-sb.install arch = x86_64 depends = dracut depends = efitools diff --git a/55-efi-key.hook b/55-efi-key.hook index 1670bbdddeb2..477febe3d7b7 100644 --- a/55-efi-key.hook +++ b/55-efi-key.hook @@ -1,5 +1,5 @@ [Trigger] -Type = File +Type = Path Operation = Install Operation = Upgrade Target = usr/lib/modules/*/pkgbase @@ -9,4 +9,3 @@ Target = usr/lib/dracut/* Description = Waiting for EFI signing key... When = PreTransaction Exec = /usr/local/share/libalpm/scripts/efi-key -NeedsTargets diff --git a/90-dracut-install.hook b/90-dracut-install.hook index 962cca24467f..46daea1d7c47 100644 --- a/90-dracut-install.hook +++ b/90-dracut-install.hook @@ -5,13 +5,6 @@ Operation = Upgrade Target = usr/lib/modules/*/pkgbase Target = usr/lib/dracut/* -[Trigger] -Type = Package -Operation = Install -Operation = Upgrade -Operation = Remove -Target = dracut-sb - [Action] Description = Updating dracut modules... When = PostTransaction @@ -2,11 +2,12 @@ pkgname=dracut-sb pkgver=1.0.1 -pkgrel=1 +pkgrel=2 pkgdesc='dracut secure boot setup using efistub' arch=('x86_64') depends=('dracut' 'efitools' 'efibootmgr' 'sbsigntools') backup=('etc/dracut-sb/efi-key.conf') +install="${pkgname}.install" source=('55-efi-key.hook' '60-dracut-remove.hook' '90-dracut-install.hook' diff --git a/dracut-sb.install b/dracut-sb.install new file mode 100644 index 000000000000..f4fa328b73b0 --- /dev/null +++ b/dracut-sb.install @@ -0,0 +1,16 @@ +post_install() { + echo "Edit the config at /etc/dracut-sb/efi-key.conf to contain the correct info," + echo "plug in the drive with the keys, then Press Enter" + read + /usr/local/share/libalpm/scripts/efi-key + echo "" | /usr/local/share/libalpm/scripts/dracut-install +} + +post_upgrade() { + /usr/local/share/libalpm/scripts/efi-key + echo "" | /usr/local/share/libalpm/scripts/dracut-install +} + +post_remove() { + echo "" | /usr/local/share/libalpm/scripts/dracut-install +} |