From e34d76f7eb09b4789619dab5aa2f51e3fa80d876 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Tue, 22 Jun 2021 12:19:54 -0400 Subject: [PATCH] OpenSUSE 15.3 support A number of changes in opensuse 15.3 require modifying our strategy. No more XInclude. This seems to be unintentional, but it released and so we will work around it. Some somewhat incorrect values, as pointed out by new validation. --- .../suse15/profiles/hpc/autoyast | 33 +++++++++---------- .../suse15/profiles/hpc/initprofile.sh | 2 +- .../suse15/profiles/hpc/scripts/pre.sh | 12 ++++++- 3 files changed, 27 insertions(+), 20 deletions(-) diff --git a/confluent_osdeploy/suse15/profiles/hpc/autoyast b/confluent_osdeploy/suse15/profiles/hpc/autoyast index 7aec831c..8f7566e8 100644 --- a/confluent_osdeploy/suse15/profiles/hpc/autoyast +++ b/confluent_osdeploy/suse15/profiles/hpc/autoyast @@ -1,17 +1,17 @@ - + - + + + UTC + + false - - UTC - - false @@ -19,16 +19,16 @@ dynamic behavior and replace with static configuration. %%IFSLE%% - sle-module-basesystem/Module-Basesystem - sle-module-hpc/Module-HPC - sle-module-server-applications/Module-Server-Applications - sle-module-containers/Module-Containers - SLE_HPC/Product-HPC - Legacy-Module/Module-Legacy + sle-module-basesystem/Module-Basesystem + sle-module-hpc/Module-HPC + sle-module-server-applications/Module-Server-Applications + sle-module-containers/Module-Containers + SLE_HPC/Product-HPC + Legacy-Module/Module-Legacy %%ENDIFSLE%% - + %%IFSLE%% @@ -39,6 +39,7 @@ dynamic behavior and replace with static configuration. base + openssh python3 openssl chrony @@ -79,7 +80,7 @@ dynamic behavior and replace with static configuration. root %%ROOTPASSWORD%% true - + @@ -99,7 +100,6 @@ dynamic behavior and replace with static configuration. diff --git a/confluent_osdeploy/suse15/profiles/hpc/initprofile.sh b/confluent_osdeploy/suse15/profiles/hpc/initprofile.sh index 5169c88c..5d5f4c2b 100644 --- a/confluent_osdeploy/suse15/profiles/hpc/initprofile.sh +++ b/confluent_osdeploy/suse15/profiles/hpc/initprofile.sh @@ -16,5 +16,5 @@ profile=$(basename $2) if [[ $profile =~ ^sle.* ]]; then sed -i 's/%%IFSLE%%//;s/%%ENDIFSLE%%//' $2/autoyast else - sed -i 's/%%IFSLE%%//' $2/autoyast + sed -i '/%%IFSLE%%///'); do +# sed -i 's%'"%$(cat $file|tr -d '\n')"% /tmp/profile/modified.xml +#done +if grep append /tmp/bootloader.xml > /dev/null; then + sed -i 's@@'"$(tr -d '\n' < /tmp/bootloader.xml)"'@' /tmp/profile/modified.xml +fi +sed -i 's#root#root'"$(tr -d '\n' < /tmp/rootkeys.xml)"'#' /tmp/profile/modified.xml +sed -i 's@/hwclock>@/hwclock>'"$(tr -d '\n' < /tmp/timezone)"'@' /tmp/profile/modified.xml +sed -i 's@@'"$(tr -d '\n' < /tmp/pkgurl)"'@' /tmp/profile/modified.xml