Skip to content

Commit dde260a

Browse files
committed
systemvm: export $TYPE before patching ssvm/cpvm
This fixes a regression introduced in apache#2799, by exporting $TYPE before the `patch` is called to patch/extract archives for ssvm/cpvm. Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
1 parent 223a373 commit dde260a

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

systemvm/debian/opt/cloud/bin/setup/cloud-early-config

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,10 @@ get_boot_params() {
150150
esac
151151
}
152152

153+
get_systemvm_type() {
154+
export TYPE=$(grep -Po 'type=\K[a-zA-Z]*' $CMDLINE)
155+
}
156+
153157
patch() {
154158
local PATCH_MOUNT=/media/cdrom
155159
local patchfile=$PATCH_MOUNT/cloud-scripts.tgz
@@ -216,11 +220,11 @@ start() {
216220

217221
config_guest
218222
get_boot_params
223+
get_systemvm_type
219224
patch
220225
sync
221226
sysctl -p
222227

223-
export TYPE=$(grep -Po 'type=\K[a-zA-Z]*' $CMDLINE)
224228
log_it "Configuring systemvm type=$TYPE"
225229

226230
if [ -f "/opt/cloud/bin/setup/$TYPE.sh" ]; then

0 commit comments

Comments
 (0)