diff --git a/tests/p_grub2/01_grub2_secureboot_signed.sh b/tests/p_grub2/01_grub2_secureboot_signed.sh index a92f326..fc5bd8c 100755 --- a/tests/p_grub2/01_grub2_secureboot_signed.sh +++ b/tests/p_grub2/01_grub2_secureboot_signed.sh @@ -5,7 +5,11 @@ t_Log "Running $0 - Verifying that grub2-efi is correctly signed with correct c arch=$(uname -m) -if [[ "$centos_ver" = "7" && "$arch" = "x86_64" ]] ; then +if [[ "$centos_ver" -ge 7 && "$arch" = "x86_64" ]] ; then + if [ ! -f /boot/efi/EFI/centos/grubx64.efi ];then + t_Log "grub2-efi not installed, can't test... skipping" + exit 0 + fi t_InstallPackage pesign grub2-efi pesign --show-signature --in /boot/efi/EFI/centos/grubx64.efi|egrep -q 'Red Hat Inc.|CentOS Secure Boot \(key 1\)' t_CheckExitStatus $?