diff options
author | m00133142 <meimei@huawei.com> | 2015-09-25 17:32:46 +0800 |
---|---|---|
committer | m00133142 <meimei@huawei.com> | 2015-09-29 10:38:28 +0800 |
commit | afca40052c85c04debc89e4ceff7b491f6872a84 (patch) | |
tree | 6ee8bacc23b0f4ded050d772fa80c348006f646c /jjb | |
parent | d7ae0e18441809522a9f7efe27bb40eff533b453 (diff) |
add process of building PPA into daily job
JIRA: COMPASS-80
Change-Id: Ib41f8fafa55c236e33ceef388ed89a6ce01cf378
Signed-off-by: m00133142 <meimei@huawei.com>
Diffstat (limited to 'jjb')
-rw-r--r-- | jjb/compass4nfv/compass4nfv.yml | 37 |
1 files changed, 36 insertions, 1 deletions
diff --git a/jjb/compass4nfv/compass4nfv.yml b/jjb/compass4nfv/compass4nfv.yml index 57b6eabc6..30643f5dd 100644 --- a/jjb/compass4nfv/compass4nfv.yml +++ b/jjb/compass4nfv/compass4nfv.yml @@ -281,6 +281,7 @@ branch: 'master' builders: + - 'compass-make-ppa' - 'compass-build' - 'compass-upload-artifact' - 'compass-workspace-cleanup' @@ -362,6 +363,12 @@ - string: name: installer_ip default: "10.1.0.12" + - string: + name: PPA_REPO + default: "http://58.251.166.184:9999" + - string: + name: PPA_CACHE + default: "$WORKSPACE/work/repo/" ######################## # builder macros @@ -373,7 +380,30 @@ #!/bin/bash echo "Hello World!" - +- builder: + name: 'compass-make-ppa' + builders: + - shell: | + #!/bin/bash + set -x + set -o errexit + set -o nounset + set -o pipefail + # make ppa + cd $WORKSPACE/ + ./build/make_repo.sh + # calc MD5 of ppa + cd $PPA_CACHE + for i in `find *.gz *.iso *.img -type f` + do + md5="md5sum $i | cut -d ' ' -f1" + echo $md5 > $i.md5 + done + # upload PPA + for i in `find *.* -type f` + do + curl -T $i $PPA_REPO + done - builder: name: 'compass-build' @@ -397,6 +427,11 @@ export OPNFV_ARTIFACT_VERSION=$(date -u +"%Y-%m-%d_%H-%M-%S") # start the build + if [ -d $PPA_CACHE ] + then + cp $PPA_CACHE/*.tar.gz $PPA_CACHE/*.iso $PPA_CACHE/*.img $CACHE_DIRECTORY/ -f + fi + cd $WORKSPACE/ ./build.sh --iso-dir $BUILD_DIRECTORY/ --iso-name compass.iso -c $CACHE_DIRECTORY |