From 8b18c329253408d37ba0b0c071caa14e7aa94a11 Mon Sep 17 00:00:00 2001 From: Nikita Dubrovskii Date: Tue, 5 Oct 2021 16:03:52 +0200 Subject: [PATCH] coreos-boot-edit: abort if system has several boot partitions Signed-off-by: Nikita Dubrovskii --- .../lib/dracut/modules.d/35coreos-ignition/coreos-boot-edit.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/overlay.d/05core/usr/lib/dracut/modules.d/35coreos-ignition/coreos-boot-edit.sh b/overlay.d/05core/usr/lib/dracut/modules.d/35coreos-ignition/coreos-boot-edit.sh index 3b16813b46..0d889a3530 100755 --- a/overlay.d/05core/usr/lib/dracut/modules.d/35coreos-ignition/coreos-boot-edit.sh +++ b/overlay.d/05core/usr/lib/dracut/modules.d/35coreos-ignition/coreos-boot-edit.sh @@ -14,6 +14,9 @@ karg() { echo "${value}" } +# Ensure we have just 1 boot partition or fail otherwise +/usr/bin/rdcore single-partition boot + # Mount /boot. Note that we mount /boot but we don't unmount it because we # are run in a systemd unit with MountFlags=slave so it is unmounted for us. bootmnt=/mnt/boot_partition