From a146a54172aa15d0f858032b2cec90a2784029ac Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Fri, 3 Dec 2021 08:48:27 -0500 Subject: [PATCH] Move ignition to profile private data, extracted --- confluent_osdeploy/coreos/profiles/default/initprofile.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/confluent_osdeploy/coreos/profiles/default/initprofile.sh b/confluent_osdeploy/coreos/profiles/default/initprofile.sh index eef2336a..d783fc6e 100644 --- a/confluent_osdeploy/coreos/profiles/default/initprofile.sh +++ b/confluent_osdeploy/coreos/profiles/default/initprofile.sh @@ -1,7 +1,12 @@ #!/bin/sh +profname=$(basename $2) +if file -L $1/images/ignition.img | grep gzip > /dev/null; then + mkdir -p /var/lib/confluent/private/os/${profname}/pending/ + cd /var/lib/confluent/private/os/${profname}/pending/ + zcat $1/images/ignition.img | cpio -dumiv +fi ln -s $1/images/pxeboot/vmlinuz $2/boot/kernel && \ ln -s $1/images/pxeboot/initrd.img $2/boot/initramfs/distribution && \ -ln -s $1/images/ignition.img $2/boot/initramfs/ignition.img && \ mkdir -p $2/boot/efi/boot/ && \ ln -s $1/images/pxeboot/rootfs.img $2/ && \ (mcopy -i $1/images/efiboot.img ::efi/redhat/grubx64.efi $2/boot/efi/boot/ || \