Support opera test in functest releng 05/32405/4
authorHarry Huang <huangxiangyu5@huawei.com>
Thu, 30 Mar 2017 08:09:48 +0000 (16:09 +0800)
committerhuangxiangyu <huangxiangyu5@huawei.com>
Wed, 3 May 2017 09:04:49 +0000 (17:04 +0800)
Because opera vnf test requires Open-O msb ip and the independency
of this test case, set specific docker env vars for compass4nfv
os-nosdn-openo-ha scenario.

Change-Id: I486e3896dc86d29cf93818b317675c088c1c5198
Signed-off-by: Harry Huang <huangxiangyu5@huawei.com>
jjb/functest/functest-daily-jobs.yml
jjb/functest/set-functest-env.sh

index e8d1432..0a2a219 100644 (file)
                 - 'vims'
                 - 'multisite'
                 - 'parser'
+                - 'opera_vims'
         - string:
             name: TESTCASE_OPTIONS
             default: ''
index 05e3d57..569f371 100755 (executable)
@@ -70,6 +70,15 @@ envs="-e INSTALLER_TYPE=${INSTALLER_TYPE} -e INSTALLER_IP=${INSTALLER_IP} \
     -e NODE_NAME=${NODE_NAME} -e DEPLOY_SCENARIO=${DEPLOY_SCENARIO} \
     -e BUILD_TAG=${BUILD_TAG} -e CI_DEBUG=${CI_DEBUG} -e DEPLOY_TYPE=${DEPLOY_TYPE}"
 
+if [[ ${INSTALLER_TYPE} == 'compass' && ${DEPLOY_SCENARIO} == *'os-nosdn-openo-ha'* ]]; then
+    ssh_options="-o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no"
+    openo_msb_port=${openo_msb_port:-80}
+    openo_msb_endpoint="$(sshpass -p'root' ssh 2>/dev/null $ssh_options root@${installer_ip} \
+    'mysql -ucompass -pcompass -Dcompass -e "select package_config from cluster;" \
+    | sed s/,/\\n/g | grep openo_ip | cut -d \" -f 4'):$openo_msb_port"
+
+    envs=${env}" -e OPENO_MSB_ENDPOINT=${openo_msb_endpoint}"
+fi
 
 volumes="${results_vol} ${sshkey_vol} ${stackrc_vol} ${rc_file_vol}"