Merge changes from topic 'packer'
authorAndrew Grimberg <agrimberg@linuxfoundation.org>
Thu, 26 Jan 2017 15:38:22 +0000 (15:38 +0000)
committerGerrit Code Review <gerrit@opendaylight.org>
Thu, 26 Jan 2017 15:38:22 +0000 (15:38 +0000)
* changes:
  Update java-builder csit image
  Move HBase/Cassandra/ElasticSearch to packer

jjb/iotdm/iotdm-csit-basic.yaml
jjb/opendaylight-infra-push-gerrit-patch.sh [new file with mode: 0644]
jjb/releng-macros.yaml

index ecf14b1b9a450035488e9f95a003b0cbcfdd0270..2871164e39d746a4ffca4d33762bcb7a9a005e10 100644 (file)
@@ -33,7 +33,7 @@
             scope: 'all'
 
     # Features to install
-    install-features: 'odl-iotdm-onem2m'
+    install-features: 'odl-onem2mall-iotdm'
 
     # Robot custom options
     robot-options: ''
diff --git a/jjb/opendaylight-infra-push-gerrit-patch.sh b/jjb/opendaylight-infra-push-gerrit-patch.sh
new file mode 100644 (file)
index 0000000..6679d27
--- /dev/null
@@ -0,0 +1,20 @@
+#!/bin/bash
+CHANGE_ID=`ssh -p 29418 jenkins-$SILO@git.opendaylight.org gerrit query \
+               limit:1 owner:self is:open project:{project} \
+               message:'{gerrit-commit-message}' \
+               topic:{gerrit-topic} | \
+               grep 'Change-Id:' | \
+               awk '{{ print $2 }}'`
+
+if [ -z "$CHANGE_ID" ]; then
+    git commit -sm "{gerrit-commit-message}"
+else
+    git commit -sm "{gerrit-commit-message}" -m "Change-Id: $CHANGE_ID"
+fi
+
+git status
+git remote add gerrit ssh://jenkins-$SILO@git.opendaylight.org:29418/releng/builder.git
+
+# Don't fail the build if this command fails because it's possible that there
+# is no changes since last update.
+git review --yes -t {gerrit-topic} || true
index 286cb4641592635ed7de4232c93f823aa997cebc..94f03fd06edd44f19b7f92cc24f63b9fecf1f445 100644 (file)
         - shell: !include-raw: opendaylight-infra-stack.sh
         - shell: !include-raw-escape: opendaylight-infra-copy-ssh-keys.sh
 
+- builder:
+    name: opendaylight-infra-push-gerrit-patch
+    # opendaylight-infra-push-gerrit-patch.sh allows a job to push a patch to
+    # Gerrit in an automated fashion. This is meant for tasks that creates
+    # the same patch regularly and needs the ability to detect if an unreviewed
+    # patch already exists. In which case it will update the existing patch.
+    #
+    # Note: This patch assumes the $WORKSPACE contains the project repo with
+    #       the files changed already "git add" and waiting for a "git commit" call.
+    #
+    # This script requires the following JJB variables to be passed in:
+    #     {project}       Gerrit project-name
+    #     {gerrit-topic}  Gerrit topic, please make a unique topic.
+    #     {gerrit-commit-message}  Commit message to assign to commit.
+    builders:
+        - shell: !include-raw: opendaylight-infra-push-gerrit-patch.sh
+
 - builder:
     name: distribute-build-url
     # Place URL of the current run of a build job to a file at given path.