[lxc-devel] [lxc-ci/master] images/opensuse: Add check for shim-install

monstermunchkin on Github lxc-bot at linuxcontainers.org
Wed Mar 4 17:45:29 UTC 2020


A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 357 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20200304/344e7858/attachment.bin>
-------------- next part --------------
From 4d189e8faf2f1a43e218d45fee14f1efa3b47036 Mon Sep 17 00:00:00 2001
From: Thomas Hipp <thomas.hipp at canonical.com>
Date: Wed, 4 Mar 2020 18:44:52 +0100
Subject: [PATCH] images/opensuse: Add check for shim-install

Signed-off-by: Thomas Hipp <thomas.hipp at canonical.com>
---
 images/opensuse.yaml | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/images/opensuse.yaml b/images/opensuse.yaml
index 847a7f2..50185bf 100644
--- a/images/opensuse.yaml
+++ b/images/opensuse.yaml
@@ -256,8 +256,15 @@ actions:
      mount -t tmpfs tmpfs /sys/firmware
      mkdir /sys/firmware/efi
      grub2-mkconfig -o /boot/grub2/grub.cfg
-     shim-install --no-nvram --removable
-     shim-install --no-nvram
+
+     if which shim-install; then
+      shim-install --no-nvram --removable
+      shim-install --no-nvram
+     else
+      grub-install --no-nvram --removable
+      grub-install --no-nvram
+     fi
+
      grub2-mkconfig -o /boot/grub2/grub.cfg
      umount /sys/firmware
      sed -i "s#root=[^ ]*#root=/dev/sda2#g" /boot/grub2/grub.cfg


More information about the lxc-devel mailing list