From 82611300e75c39500f3302efe5cfe56e4c11b67b Mon Sep 17 00:00:00 2001 From: Hongxu Jia Date: Fri, 22 Apr 2022 00:50:03 +0800 Subject: [PATCH] Debian KS: split Common Functions Script as %ks-early Due to commit [9cdcb08b lat installer: improve kickstart hook position] [1] applied by meta-lat, it places `%pre-part' hook after variable INSTDEV is parsed and set correctly. Then we will know which disk to install in the hook. It also adds a new `%ks-early' hook to place to `%pre-part' original position The original Common Functions Script includes two parts, one is Common Functions Script, another is pre disk setup common, split the first part as `%ks-early' hook [1] https://github.com/Wind-River/meta-lat/commit/ 9cdcb08b9876e842d75ee7ba6e90bde1d67ac2c6 Story: 2009964 Task: 45152 Test Plan: PASS - Rebuild kickstart PASS - Build ISO PASS - BIOS Boot/Install ISO on Nuc5,Nuc7 and Dell9010 Depends-On: https://review.opendev.org/c/starlingx/integ/+/838688 Depends-On: https://review.opendev.org/c/starlingx/metal/+/838994 Depends-On: https://review.opendev.org/c/starlingx/metal/+/838993 Signed-off-by: Hongxu Jia Change-Id: I80354f8d60a706ada285655d86876fc6eb1129bf --- kickstart/files/kickstart.cfg | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/kickstart/files/kickstart.cfg b/kickstart/files/kickstart.cfg index 0cfef6f4..01247a6b 100644 --- a/kickstart/files/kickstart.cfg +++ b/kickstart/files/kickstart.cfg @@ -65,8 +65,8 @@ # file that can be loaded from any of the other hook sections. # ########################################################################### -# Pre Partition - Common Functions Script -%pre-part --interpreter=/bin/bash +# Kickstart Early - Common Functions Script +%ks-early --interpreter=/bin/bash cat << EOF >> /tmp/lat/ks_functions.sh @@ -569,7 +569,7 @@ SCRATCH_VOL_SIZE=16000 EOF chmod 755 /tmp/lat/ks_functions.sh -HOOK_LABEL="pre-part" +HOOK_LABEL="ks-early" . /tmp/lat/ks_functions.sh ########################################################################## @@ -690,6 +690,13 @@ check_execs # TODO: The installer does not have 'timezone' # Does LAT handle this ? wlog "timezone not set ; 'timezone --nontp --utc UTC'" +true +%end + +# Pre Partition - Pre Disk Setup Common Script +%pre-part --interpreter=/bin/bash +HOOK_LABEL="pre-part" +. /tmp/lat/ks_functions.sh ##################################################### # From pre_disk_setup_common.cfg