From 90a0b59e6b1d04b5acb6dccae282beb61523004d Mon Sep 17 00:00:00 2001 From: Martin Pietsch <martin.pietsch@tu-dresden.de> Date: Mon, 18 Nov 2019 15:41:40 +0100 Subject: [PATCH] mounting efivarfs in EFI environment --- files/functions.sh | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/files/functions.sh b/files/functions.sh index 18342d1..5b442fb 100755 --- a/files/functions.sh +++ b/files/functions.sh @@ -66,11 +66,21 @@ runChroot(){ mount devpts /target/dev/pts -t devpts mount none /target/proc -t proc mount none /target/sys -t sysfs + + if [ -d /sys/firmware/efi ]; + then + mount none /target/sys/firmware/efi/efivars -t efivarfs + fi LANG=C.UTF-8 chroot /target $1 + if [ -d /sys/firmware/efi ]; + then + umount /target/sys/firmware/efi/efivars + fi + umount /target/sys umount /target/proc umount /target/dev/pts - umount /dev /target/dev + umount /target/dev } -- GitLab