Merge "KVMFORNFV: Common build packages for daily test cases"
authorAric Gardner <agardner@linuxfoundation.org>
Mon, 15 May 2017 19:26:38 +0000 (19:26 +0000)
committerGerrit Code Review <gerrit@opnfv.org>
Mon, 15 May 2017 19:26:38 +0000 (19:26 +0000)
jjb/apex/apex-upload-artifact.sh
jjb/apex/apex.yml
jjb/apex/apex.yml.j2

index c886296..f543e2d 100755 (executable)
@@ -15,7 +15,9 @@ echo
 
 BUILD_DIRECTORY=$WORKSPACE/../$BUILD_DIRECTORY
 
-source $BUILD_DIRECTORY/../opnfv.properties
+if [[ ! "$ARTIFACT_VERSION" =~ dev ]]; then
+  source $BUILD_DIRECTORY/../opnfv.properties
+fi
 
 importkey () {
   # clone releng repository
@@ -85,7 +87,8 @@ uploadsnap () {
 
 uploadimages () {
   # Uploads dev tarball
-  export OPNFV_ARTIFACT_VERSION="dev${GERRIT_CHANGE_NUMBER}${GERRIT_PATCHSET_NUMBER}"
+  GERRIT_PATCHSET_NUMBER=$(echo $GERRIT_REFSPEC | grep -Eo '[0-9]+$')
+  export OPNFV_ARTIFACT_VERSION="dev${GERRIT_CHANGE_NUMBER}_${GERRIT_PATCHSET_NUMBER}"
   echo "Uploading development build tarball"
   pushd $BUILD_DIRECTORY > /dev/null
   tar czf apex-${OPNFV_ARTIFACT_VERSION}.tar.gz *.qcow2
index c3e23ba..1e13cbd 100644 (file)
             description: "Directory where the build artifact will be located upon the completion of the build."
         - string:
             name: CACHE_DIRECTORY
-            default: $HOME/opnfv/cache{gs-pathname}
+            default: $HOME/opnfv/apex-cache{gs-pathname}
             description: "Directory where the cache to be used during the build is located."
         - string:
             name: GIT_BASE
index 2e179d4..ade876c 100644 (file)
             description: "Directory where the build artifact will be located upon the completion of the build."
         - string:
             name: CACHE_DIRECTORY
-            default: $HOME/opnfv/cache{gs-pathname}
+            default: $HOME/opnfv/apex-cache{gs-pathname}
             description: "Directory where the cache to be used during the build is located."
         - string:
             name: GIT_BASE