aboutsummaryrefslogtreecommitdiffstats
path: root/jjb/release-jjb-jellyfish-snapshot/include-release-jjb-jellyfish-snapshot-rsync.sh
diff options
context:
space:
mode:
authorJan-Simon Moeller <jsmoeller@linuxfoundation.org>2020-06-29 12:34:31 +0200
committerJan-Simon Moeller <jsmoeller@linuxfoundation.org>2020-06-29 12:34:31 +0200
commit154d2b4db41b03c40c880b54b241f82102e99958 (patch)
treea54e5ae913ce6315e86849a068022bd2c55cd5dd /jjb/release-jjb-jellyfish-snapshot/include-release-jjb-jellyfish-snapshot-rsync.sh
parente3f8aef07fe8ea1dc9b22692ac19c6907ef88cfb (diff)
Update jenkins template for Jumping Jellyfish release
Add jobs for the JJ release. Bug-AGL: SPEC-3460 Signed-off-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org> Change-Id: I0c104bdf97056cf52cf0f4e7fd9321cca24adf7c
Diffstat (limited to 'jjb/release-jjb-jellyfish-snapshot/include-release-jjb-jellyfish-snapshot-rsync.sh')
-rw-r--r--jjb/release-jjb-jellyfish-snapshot/include-release-jjb-jellyfish-snapshot-rsync.sh57
1 files changed, 57 insertions, 0 deletions
diff --git a/jjb/release-jjb-jellyfish-snapshot/include-release-jjb-jellyfish-snapshot-rsync.sh b/jjb/release-jjb-jellyfish-snapshot/include-release-jjb-jellyfish-snapshot-rsync.sh
new file mode 100644
index 00000000..9be7c6f8
--- /dev/null
+++ b/jjb/release-jjb-jellyfish-snapshot/include-release-jjb-jellyfish-snapshot-rsync.sh
@@ -0,0 +1,57 @@
+#!/bin/bash
+
+#set -x
+set -e
+echo "#######################################"
+echo "#######################################"
+ls -alh
+echo "#######################################"
+echo "#######################################"
+tree -L 2
+echo "#######################################"
+echo "#######################################"
+set | grep MACHINE
+echo "#######################################"
+echo "#######################################"
+set
+echo "#######################################"
+echo "#######################################"
+
+cd repoclone/output
+
+export REMOTEDST="/srv/download/AGL/upload/ci/${RELEASE_BRANCH}/${RELEASE_VERSION}/${MACHINE}/"
+export RSYNCDST="jenkins-slave@10.30.72.8:${REMOTEDST}"
+export RSYNCSRC=$(pwd)/UPLOAD/${MACHINE}
+
+# construct upload folder
+mv UPLOAD UPLOAD2 || true
+rm -rf UPLOAD2 || true
+mkdir -p UPLOAD/${MACHINE}
+export DEST=$(pwd)/UPLOAD/${MACHINE}
+
+# save space ... remove the rpms
+rm -rf tmp/deploy/rpm || true
+
+rsync -avr --progress --delete tmp/deploy $DEST/
+rsync -avr --progress --delete tmp/log $DEST/
+
+cp ../../current_default.xml $DEST/${MACHINE}_repo_default.xml
+cp conf/local.conf $DEST/local.conf
+cp conf/auto.conf $DEST/auto.conf
+echo "$BUILD_URL" > $DEST/jenkins.build.url
+
+tree $DEST
+
+ls -alhR $DEST
+
+
+
+echo "would do rsync -avr -e \"ssh -o StrictHostKeyChecking=no\" $RSYNCSRC $RSYNCDST "
+
+if test x"yes" = x"$UPLOAD" ; then
+ ssh -o StrictHostKeyChecking=no jenkins-slave@10.30.72.8 rm -rf ${REMOTEDST}
+ ssh -o StrictHostKeyChecking=no jenkins-slave@10.30.72.8 mkdir -p ${REMOTEDST}
+ rsync --delete -avr -e "ssh -o StrictHostKeyChecking=no" $RSYNCSRC/* $RSYNCDST
+fi
+
+exit 0 \ No newline at end of file