summaryrefslogtreecommitdiffstats
path: root/jjb/include-raw-jjb-update.sh
diff options
context:
space:
mode:
authorAndrew Grimberg <agrimberg@linuxfoundation.org>2015-11-23 08:48:17 -0800
committerAndrew Grimberg <agrimberg@linuxfoundation.org>2015-11-23 08:48:17 -0800
commit21e6159d981bc45301b3727423336d08a49fe53f (patch)
treef3507a6d9a7aeaddad15d5baeb2d25c76f9a64d2 /jjb/include-raw-jjb-update.sh
parent883d77c5c804b0f1e9f1370c89f8fe38672188b5 (diff)
Initial JJB self-hosting job definitions
These are the base definitions for having Jenkins validate and merge the JJB jobs that manage the Jenkins instance. Change-Id: Ic028248bc6cacb86d4db8c1e0f5f924640892c99 Signed-off-by: Andrew Grimberg <agrimberg@linuxfoundation.org>
Diffstat (limited to 'jjb/include-raw-jjb-update.sh')
-rw-r--r--jjb/include-raw-jjb-update.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/jjb/include-raw-jjb-update.sh b/jjb/include-raw-jjb-update.sh
new file mode 100644
index 000000000..f1aaaa8ae
--- /dev/null
+++ b/jjb/include-raw-jjb-update.sh
@@ -0,0 +1,10 @@
+jenkins-jobs update --delete-old jjb/
+
+# Submit patches for any jobs that can be auto updated
+function submitJJB {
+ git commit -asm "Update automated project templates"
+ git push origin HEAD:refs/for/master
+}
+
+gitdir=$(git rev-parse --git-dir); scp -p -P 29418 rotterdam-jobbuilder@git.opendaylight.org:hooks/commit-msg ${gitdir}/hooks/
+git diff --exit-code || submitJJB