Adapt test jobs to stack oriented framework 33/5133/2
authorFatih Degirmenci <fatih.degirmenci@est.tech>
Tue, 23 Jun 2020 09:32:32 +0000 (09:32 +0000)
committerFatih Degirmenci <fatih.degirmenci@est.tech>
Tue, 23 Jun 2020 13:15:10 +0000 (13:15 +0000)
Change-Id: If7ac1c111918b28a6f6d16b3108ce75b0e8f9b11

jjb/engine/scripts/download-artifact.sh
jjb/engine/scripts/functest.sh
jjb/engine/scripts/generate-change-metadata.sh
jjb/engine/scripts/package.sh
jjb/engine/verify-jobs/engine-verify-deploy-test.yaml

index 2257c011e874b3285685ae84e73eebd3e16d8c25..68e8d03998a6d17f1388708c7933d34bdb5ba4de 100755 (executable)
@@ -24,7 +24,7 @@ set -o errexit
 if [[ "$EXECUTION_MODE" == "offline-deployment" ]]; then
   # ensure we delete leftovers due to lack of disk space
   sudo /bin/rm -rf /tmp/$INSTALLER_FILE ~/.ara \
-      /opt/engine /opt/test /opt/stack /httpboot > /dev/null 2>&1 || true
+      /opt/test /opt/stack /httpboot > /dev/null 2>&1 || true
   sudo docker ps -a --format {{.ID}} | xargs -n 1 sudo docker stop > /dev/null 2>&1 || true
   sudo docker ps -a --format {{.ID}} | xargs -n 1 sudo docker rm > /dev/null 2>&1 || true
   sudo docker images -a --format {{.ID}} | xargs -n 1 sudo docker rmi -f > /dev/null 2>&1 || true
index b43628f1e04c6e67760c998e423edcbddee0ee9a..14a2b0cb7d94537e721c1136fa3bddc368466081 100755 (executable)
@@ -32,14 +32,8 @@ if [[ "$EXECUTION_MODE" == "offline-deployment" && "$SLAVE_LABEL" != "baremetal-
   exit 0
 fi
 
-if [[ "$GERRIT_PROJECT" == "infra/installer/kolla" ]]; then
-  echo "Info  : Setting installer to kolla and scenario to os-nosdn-nofeature"
-  export INSTALLER_TYPE="kolla"
-  export DEPLOY_SCENARIO="os-nosdn-nofeature"
-fi
-
 # NOTE (fdegir): delete unnecessary stuff to free up space on baremetal jumphost
-sudo /bin/rm -rf /tmp/$ARTIFACT_TO_DOWNLOAD ~/.ara \
+sudo /bin/rm -rf /tmp/$BUILD_ARTIFACTS ~/.ara \
     /opt/test /opt/stack /httpboot /opt/engine/offline/binaries /opt/engine/offline/dib \
     /tmp/kubespray_cache > /dev/null 2>&1 || true
 sudo docker images -a --format {{.ID}} | xargs -n 1 sudo docker rmi -f > /dev/null 2>&1 || true
@@ -49,4 +43,6 @@ cd $HOME && /bin/rm -rf $WORKSPACE
 git clone -q $TEST_REPO_URL $WORKSPACE
 
 cd $WORKSPACE/test
-./test.sh -f $TEST_FW -t $TEST_SUITE -i $INSTALLER_TYPE -s $DEPLOY_SCENARIO -d $YARDSTICK_DISPATCHER
+./test.sh -f $TEST_FW -t $TEST_SUITE -s $STACK_TYPE -y $YARDSTICK_DISPATCHER -d
+
+# vim: set ts=2 sw=2 expandtab:
index f02b348065852c588a19c8ba101bba678358bbda..680042298c9d76194c63112107b38e268112d05d 100755 (executable)
@@ -87,6 +87,7 @@ else
   export STACK_TYPE=kubernetes
   export STACK_VERSION=$STACK_VERSION
   echo "STACK_TYPE=kubernetes" >> "$CHANGE_METADATA_FILE"
+  echo "STACK_VERSION=$STACK_VERSION" >> "$CHANGE_METADATA_FILE"
   echo "NORDIX_$(echo $ENGINE_COMPONENT | tr a-z A-Z)_VERSION=$GERRIT_PATCHSET_REVISION" >> "$CHANGE_METADATA_FILE"
   echo "NORDIX_$(echo $ENGINE_COMPONENT | tr a-z A-Z)_REFSPEC=$GERRIT_REFSPEC" >> "$CHANGE_METADATA_FILE"
 fi
index 11700a957da2e89dc8933ea9ae1f052c5f789faa..38f2955b82addaa692844dec144319639568da9d 100755 (executable)
@@ -23,9 +23,9 @@ set -o errexit
 set -o pipefail
 
 source "$WORKSPACE/change.properties"
-echo "Info  : Packaging stack $STACK_TO_PACKAGE"
+echo "Info  : Packaging stack $STACK_TYPE"
 
 cd "$WORKSPACE/engine"
-./package.sh -s "$STACK_TO_PACKAGE" -d
+./package.sh -s "$STACK_TYPE" -v "$STACK_VERSION" -d
 
 # vim: set ts=2 sw=2 expandtab:
index faf27d461d8460cb96da023b1f50d18edaa5f1b4..2702466c16a71a630f50896376196649cd85c357 100644 (file)
@@ -30,8 +30,6 @@
       - online:
           disabled: false
           execution-mode: online-deployment
-          pdf: 'https://gerrit.nordix.org/gitweb?p=infra/hwconfig.git;a=blob_plain;f=pods/nordix-vpod1-pdf.yml'
-          idf: 'https://gerrit.nordix.org/gitweb?p=infra/hwconfig.git;a=blob_plain;f=pods/nordix-vpod1-idf.yml'
           successful: false
           failed: false
           unstable: false
@@ -39,8 +37,6 @@
       - offline:
           disabled: false
           execution-mode: offline-deployment
-          pdf: 'file:///opt/engine/offline/git/hwconfig/pods/nordix-vpod1-pdf.yml'
-          idf: 'file:///opt/engine/offline/git/hwconfig/pods/nordix-vpod1-idf.yml'
           successful: false
           failed: false
           unstable: false
           provisioner-type: 'bifrost'
           slave-type: 'vpod'
           gated-projects: 'infra/engine|infra/provisioner/bifrost'
+          pdf: 'https://gerrit.nordix.org/gitweb?p=infra/hwconfig.git;a=blob_plain;f=pods/nordix-vpod1-pdf.yml'
+          idf: 'https://gerrit.nordix.org/gitweb?p=infra/hwconfig.git;a=blob_plain;f=pods/nordix-vpod1-idf.yml'
       - cloud:
           provisioner-type: 'heat'
           slave-type: 'jumphost'
           gated-projects: 'infra/engine|infra/provisioner/heat'
+          pdf: "https://gerrit.nordix.org/gitweb?p=infra/provisioner/heat.git;a=blob_plain;f=playbooks/roles/create-stack/files/heat-environment-city-ubuntu1804.yaml"
+          idf: "https://gerrit.nordix.org/gitweb?p=infra/provisioner/heat.git;a=blob_plain;f=playbooks/roles/create-stack/files/heat-idf.yaml"
 
     distro:
       - ubuntu1804
           description: 'Name of heat-environment file to use.'
       - string:
           name: HEAT_STACK_NAME
-          default: "nordix-cicd-verify-engine-online-{distro}-$GERRIT_CHANGE_NUMBER"
+          default: "nordix-cicd-verify-engine-{environment-type}-{distro}-$GERRIT_CHANGE_NUMBER"
           description: 'Name of the created stack'
       - string:
           name: KEYPAIR_NAME
-          default: "keypair-nordix-cicd-verify-engine-online-{distro}-$GERRIT_CHANGE_NUMBER"
+          default: "keypair-nordix-cicd-verify-engine-{environment-type}-{distro}-$GERRIT_CHANGE_NUMBER"
           description: 'Name of the created keypair'
       - string:
           name: USE_PREBUILT_DEPLOYMENT_IMAGE