1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-27 18:55:40 +03:00

mkosi: Use proper check to detect whether we're in a VM

This commit is contained in:
Daan De Meyer 2023-05-26 17:38:23 +02:00
parent fdeed78a71
commit 4dfb458f42

View File

@ -4,7 +4,7 @@
systemctl --failed --no-legend | tee /failed-services
# Check that secure boot keys were properly enrolled.
if [[ -d /sys/firmware/efi/efivars/ ]]; then
if ! systemd-detect-virt --container; then
cmp /sys/firmware/efi/efivars/SecureBoot-8be4df61-93ca-11d2-aa0d-00e098032b8c <(printf '\6\0\0\0\1')
cmp /sys/firmware/efi/efivars/SetupMode-8be4df61-93ca-11d2-aa0d-00e098032b8c <(printf '\6\0\0\0\0')
grep -q this_should_be_here /proc/cmdline