Use uri for sdf and stop setting DEPLOY_SCENARIO parameter 20/1120/1
authorFatih Degirmenci <fdegir@gmail.com>
Tue, 7 May 2019 09:20:53 +0000 (11:20 +0200)
committerFatih Degirmenci <fdegir@gmail.com>
Tue, 7 May 2019 09:21:20 +0000 (11:21 +0200)
Change-Id: Ied5bd18d3b0090ee8d41810b4a68e30c5677b39f

jjb/cloud-infra/cloud-infra-macros.yaml
jjb/cloud-infra/cloud-infra-scenario-deploy.sh
jjb/cloud-infra/cloud-infra-scenario-test.sh
jjb/cloud-infra/cloud-infra-verify-scenario.yaml
jjb/cloud-infra/determine-scenario.sh
jjb/cloud-infra/prepare-for-scenario-deploy.sh
jjb/cloud-infra/prepare-for-scenario-test.sh

index 268c9877a0acdc6234b27e7329936288a6bdba89..2ff2a47ccc0e22caebc66202dbae7e51673dbc0c 100644 (file)
@@ -59,7 +59,7 @@
       - inject:
           properties-file: "$WORKSPACE/change.properties"
       - description-setter:
-          description: "Installer: $INSTALLER_TYPE - Scenario: $DEPLOY_SCENARIO"
+          description: $INSTALLER_TYPE - $DEPLOY_SCENARIO"
 
 - builder:
     name: 'cloud-infra-scenario-deploy-macro'
index e81da3362960bc3c457ae4a9d44f36be1b61cbb8..a52234aa29864948b1d723ee566ee8f3be94f361 100644 (file)
@@ -32,8 +32,8 @@ else
 fi
 
 # clone infra/engine repository
-echo "Deploying scenario $DEPLOY_SCENARIO using $INSTALLER_TYPE"
+echo "Info: Deploying scenario $DEPLOY_SCENARIO using $INSTALLER_TYPE"
 cd $WORKSPACE
-./engine/deploy.sh -d $INSTALLER_TYPE -s $DEPLOY_SCENARIO -p $PDF -i $IDF -b $WORKSPACE/sdf.yml -c
+./engine/deploy.sh -d $INSTALLER_TYPE -s $DEPLOY_SCENARIO -p $PDF -i $IDF -b file://$WORKSPACE/sdf.yml -c
 
 # vim: set ts=2 sw=2 expandtab:
index e1b92d17d28af16ad038cdf6bcc420d8a8e9da99..7bef37332cde4ae02fcd7214335a3d4e36d1f2bc 100644 (file)
@@ -27,7 +27,7 @@ set -o nounset
 set -o pipefail
 
 # execute cloud engine test.sh script with arguments
-echo "Testing scenario $DEPLOY_SCENARIO deployed using $INSTALLER_TYPE"
+echo "Info: Testing scenario $DEPLOY_SCENARIO deployed using $INSTALLER_TYPE"
 cd $WORKSPACE
 ./test/test.sh -c -f $TEST_FW -t $TEST_SUITE -s $DEPLOY_SCENARIO
 
index 14894ec1bf4943fba5dbb67a439019ef98b65e11..fa473125e8eea728488b3007de27639d465c1f67 100644 (file)
           name: DIB_OS_ELEMENT
           default: '{dib_os_element}'
           description: 'DIB OS Element to use for building the deployment image to provision target nodes with'
-      - string:
-          name: DEPLOY_SCENARIO
-          default: 'k8-calico-nofeature'
-          description: 'Scenario to deploy and test'
       - string:
           name: TEST_SUITE
           default: 'healthcheck'
                 IPA_DIB_OS_ELEMENT=$IPA_DIB_OS_ELEMENT
                 DIB_OS_RELEASE=$DIB_OS_RELEASE
                 DIB_OS_ELEMENT=$DIB_OS_ELEMENT
-                DEPLOY_SCENARIO=$DEPLOY_SCENARIO
                 CLEANUP=$CLEANUP
                 GERRIT_PROJECT=$GERRIT_PROJECT
                 GERRIT_BRANCH=$GERRIT_BRANCH
                 IPA_DIB_OS_ELEMENT=$IPA_DIB_OS_ELEMENT
                 DIB_OS_RELEASE=$DIB_OS_RELEASE
                 DIB_OS_ELEMENT=$DIB_OS_ELEMENT
-                DEPLOY_SCENARIO=$DEPLOY_SCENARIO
                 TEST_SUITE=$TEST_SUITE
                 CLEANUP=$CLEANUP
                 GERRIT_PROJECT=$GERRIT_PROJECT
           name: DIB_OS_ELEMENT
           default: 'ubuntu-minimal'
           description: 'DIB OS Element to use for building the deployment image to provision target nodes with. Overriden by upstream job.'
-      - string:
-          name: DEPLOY_SCENARIO
-          default: 'k8-calico-nofeature'
-          description: 'Scenario to deploy and test'
       - string:
           name: TEST_FW
           default: '{phase}'
index d3ef11f7850b0f2a881f4f49e9268fef9bd61570..8207a1eb53b63f9209548421644efb77b33ca8ee 100644 (file)
@@ -36,7 +36,7 @@ set -o pipefail
 # installer-type: kubespray
 # deploy-scenario: k8-calico-nofeature
 function override_installer_scenario() {
-  echo "Processing $GERRIT_PROJECT patchset $GERRIT_REFSPEC to determine the installer and the scenario"
+  echo "Info: Processing $GERRIT_PROJECT patchset $GERRIT_REFSPEC to determine the installer and the scenario"
   cd $WORKSPACE
   COMMIT_MESSAGE=$(git show -s --format=%B)
 
@@ -44,8 +44,8 @@ function override_installer_scenario() {
     export INSTALLER_TYPE=$(echo "$COMMIT_MESSAGE" | grep '^installer-type:' | cut -d":" -f2 | sed 's/\s*//g')
     export DEPLOY_SCENARIO=$(echo "$COMMIT_MESSAGE" | grep '^deploy-scenario:' | cut -d":" -f2 | sed 's/\s*//g')
   else
-    echo "Installer type or deploy scenario is not specified."
-    echo "Falling back to programmatically determining them."
+    echo "Info: Installer type or deploy scenario is not specified."
+    echo "Info: Falling back to programmatically determining them."
     determine_scenario
   fi
 }
@@ -55,14 +55,14 @@ function override_installer_scenario() {
 # touched.
 # TODO: this is not implented yet.
 function determine_scenario() {
-  echo "Processing $GERRIT_PROJECT patchset $GERRIT_REFSPEC"
+  echo "Info: Processing $GERRIT_PROJECT patchset $GERRIT_REFSPEC"
   cd $WORKSPACE
   COMMIT_MESSAGE=$(git show -s --format=%B)
-  echo "Not implemented!"
+  echo "Info: Not implemented!"
   exit 1
 }
 
-echo "Determining the impacted scenario and used installer"
+echo "Info: Determining the impacted scenario and used installer"
 
 declare -a DEPLOY_SCENARIO
 declare -a INSTALLER_TYPE
@@ -70,16 +70,16 @@ export PROJECT_GIT_URL=$GIT_BASE_HTTPS/$GERRIT_PROJECT
 
 override_installer_scenario
 
-echo "Writing change metadata to $WORKSPACE/change.properties"
+echo "Info: Writing change metadata to $WORKSPACE/change.properties"
 cat << EOF > $WORKSPACE/change.properties
 PROJECT_GIT_URL=$GIT_BASE_HTTPS/$GERRIT_PROJECT
 DEPLOY_SCENARIO=$DEPLOY_SCENARIO
 INSTALLER_TYPE=$INSTALLER_TYPE
 GERRIT_PATCHSET_REVISION=$GERRIT_PATCHSET_REVISION
-GERRIT_REFSPEC=$GERRIT_REFSPEC=
+GERRIT_REFSPEC=$GERRIT_REFSPEC
 EOF
 
-echo "Content of change.properties"
+echo "Info: Content of change.properties"
 echo "-------------------------------------------------------------------------"
 cat $WORKSPACE/change.properties
 echo "-------------------------------------------------------------------------"
index 16a823b34b3f59d8d0dbf5a3899a536a7a50b949..5cfc1a500c4c3db7d58de09a1dbc829dbeaffc58 100644 (file)
@@ -25,7 +25,7 @@ echo "Info: Cloning infra/engine repository"
 cd $HOME && /bin/rm -rf $WORKSPACE
 git clone -q $ENGINE_REPO_URL $WORKSPACE
 
-echo "Generating temporary SDF"
+echo "Info: Generating temporary SDF"
 cat << EOF > $WORKSPACE/sdf.yml
 scenario:
   $DEPLOY_SCENARIO:
@@ -39,7 +39,7 @@ scenario:
         distros:
           - ubuntu
 EOF
-echo "Temporary SDF content"
+echo "Info: Temporary SDF content"
 echo "-------------------------------------------------------------------------"
 cat $WORKSPACE/sdf.yml
 echo "-------------------------------------------------------------------------"
index eae6b51b1658bdbdcdb8fbfc73aa281cce171bae..aefe033a3d20c056a3b1e7c480899d206752eb59 100644 (file)
@@ -25,7 +25,7 @@ echo "Info: Cloning infra/test repository"
 cd $HOME && /bin/rm -rf $WORKSPACE
 git clone -q $TEST_REPO_URL $WORKSPACE
 
-echo "Generating temporary SDF"
+echo "Info: Generating temporary SDF"
 cat << EOF > $WORKSPACE/sdf.yml
 scenario:
   $DEPLOY_SCENARIO:
@@ -39,7 +39,7 @@ scenario:
         distros:
           - ubuntu
 EOF
-echo "Temporary SDF content"
+echo "Info: Temporary SDF content"
 echo "-------------------------------------------------------------------------"
 cat $WORKSPACE/sdf.yml
 echo "-------------------------------------------------------------------------"