From 6ac4d5ab039953fcb6589b004701054ad9661be4 Mon Sep 17 00:00:00 2001 From: Steeve Goveas Date: Thu, 8 Aug 2024 13:15:21 +0100 Subject: [PATCH] Add 'set -x' and wipefs of devices with wildcard (#77) Already implemented in bastion, PR is to update the change in git repo. --- .../root/usr/share/bastion_services/ignitions/wipe_disks.bu | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/images/fcos-bastion-image/root/usr/share/bastion_services/ignitions/wipe_disks.bu b/images/fcos-bastion-image/root/usr/share/bastion_services/ignitions/wipe_disks.bu index fa69f83..4256814 100644 --- a/images/fcos-bastion-image/root/usr/share/bastion_services/ignitions/wipe_disks.bu +++ b/images/fcos-bastion-image/root/usr/share/bastion_services/ignitions/wipe_disks.bu @@ -18,7 +18,7 @@ systemd: Wants=network-online.target [Service] Type=oneshot - ExecStartPre=-bash -c 'for i in $(lsblk -I8,259 -nd --output name); do wipefs -a /dev/$i; done' + ExecStartPre=-bash -c 'set -x; for i in $(lsblk -I8,259 -nd --output name); do wipefs -a /dev/$i*; done; set +x' ExecStartPre=-bash -c '/usr/sbin/efibootmgr -v | sed -nE "s|^Boot([0-9A-Fa-f]{4}).*HD\(.*$|\1|gp" | xargs -I% /usr/sbin/efibootmgr --delete-bootnum --bootnum %' ExecStart=/usr/bin/systemctl --no-block poweroff StandardOutput=kmsg+console