diff options
author | 2019-06-02 23:51:09 +0200 | |
---|---|---|
committer | 2019-06-02 23:51:09 +0200 | |
commit | de0cdf51a11861483b1fcc524232253ae68fbb0f (patch) | |
tree | 8c618ee00a03b579ae4ea8b0cda45ebdb984a4ce /jjb/release-jjb-halibut-snapshot/include-release-jjb-halibut-snapshot-rsync.sh | |
parent | edd0246fa62ce2d1fcbe66eef70a38ad67a0a480 (diff) |
Add release jobs to CI for HH
Change-Id: I07907b16fa5379ef68e61287c4b4f15ec4092eb0
Signed-off-by: Jan-Simon Möller <jsmoeller@linuxfoundation.org>
Diffstat (limited to 'jjb/release-jjb-halibut-snapshot/include-release-jjb-halibut-snapshot-rsync.sh')
-rw-r--r-- | jjb/release-jjb-halibut-snapshot/include-release-jjb-halibut-snapshot-rsync.sh | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/jjb/release-jjb-halibut-snapshot/include-release-jjb-halibut-snapshot-rsync.sh b/jjb/release-jjb-halibut-snapshot/include-release-jjb-halibut-snapshot-rsync.sh new file mode 100644 index 00000000..9be7c6f8 --- /dev/null +++ b/jjb/release-jjb-halibut-snapshot/include-release-jjb-halibut-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 |