From 55ffe9aead06fc13b885c5dd04a170856c35b3c9 Mon Sep 17 00:00:00 2001 From: Alexandru Avadanii Date: Thu, 17 Aug 2017 17:43:46 +0200 Subject: fuel-deploy.sh: source local_env from securedlab While at it, revert BRIDGE default value to "pxebr" after recent Fuel rework was merged in [1]. This mechanism will be leveraged by [2]. Partially reverts commit: 68195fd [1] https://gerrit.opnfv.org/gerrit/#/c/38855/ [2] https://gerrit.opnfv.org/gerrit/#/c/39521/ Change-Id: Ic61487384029a7d16547a5035a1f1b34ecbea8d4 Signed-off-by: Alexandru Avadanii --- jjb/fuel/fuel-deploy.sh | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'jjb/fuel/fuel-deploy.sh') diff --git a/jjb/fuel/fuel-deploy.sh b/jjb/fuel/fuel-deploy.sh index 29b173ae5..eebd8bc71 100755 --- a/jjb/fuel/fuel-deploy.sh +++ b/jjb/fuel/fuel-deploy.sh @@ -33,7 +33,7 @@ fi # set deployment parameters export TMPDIR=$HOME/tmpdir -BRIDGE=${BRIDGE:-,,,} +BRIDGE=${BRIDGE:-pxebr} LAB_NAME=${NODE_NAME/-*} POD_NAME=${NODE_NAME/*-} @@ -63,13 +63,20 @@ echo "Cloning securedlab repo $BRANCH" git clone ssh://jenkins-ericsson@gerrit.opnfv.org:29418/securedlab --quiet \ --branch $BRANCH +# Source local_env if present, which contains POD-specific config +local_env="${WORKSPACE}/securedlab/labs/$LAB_NAME/$POD_NAME/fuel/config/local_env" +if [ -e "${local_env}" ]; then + echo "-- Sourcing local environment file" + source "${local_env}" +fi + # log file name FUEL_LOG_FILENAME="${JOB_NAME}_${BUILD_NUMBER}.log.tar.gz" # construct the command DEPLOY_COMMAND="sudo $WORKSPACE/ci/deploy.sh -b file://$WORKSPACE/securedlab \ -l $LAB_NAME -p $POD_NAME -s $DEPLOY_SCENARIO -i file://$WORKSPACE/opnfv.iso \ - -B $BRIDGE -S $TMPDIR -L $WORKSPACE/$FUEL_LOG_FILENAME" + -B ${DEFAULT_BRIDGE:-${BRIDGE}} -S $TMPDIR -L $WORKSPACE/$FUEL_LOG_FILENAME" # log info to console echo "Deployment parameters" -- cgit 1.2.3-korg