2 ##############################################################################
3 # Copyright (c) 2016 ZTE Coreporation and others.
4 # hu.zhijiang@zte.com.cn
5 # sun.jing22@zte.com.cn
6 # All rights reserved. This program and the accompanying materials
7 # are made available under the terms of the Apache License, Version 2.0
8 # which accompanies this distribution, and is available at
9 # http://www.apache.org/licenses/LICENSE-2.0
10 ##############################################################################
14 if [[ "$JOB_NAME" =~ "merge" ]]; then
15 echo "Downloading http://$GS_URL/opnfv-gerrit-$GERRIT_CHANGE_NUMBER.properties"
16 # get the properties file for the Daisy4nfv BIN built for a merged change
17 curl -s -o $WORKSPACE/latest.properties http://$GS_URL/opnfv-gerrit-$GERRIT_CHANGE_NUMBER.properties
19 # get the latest.properties file in order to get info regarding latest artifact
20 echo "Downloading http://$GS_URL/latest.properties"
21 curl -s -o $WORKSPACE/latest.properties http://$GS_URL/latest.properties
24 # check if we got the file
25 [[ -f latest.properties ]] || exit 1
27 # source the file so we get artifact metadata
28 source latest.properties
30 # echo the info about artifact that is used during the deployment
31 OPNFV_ARTIFACT=${OPNFV_ARTIFACT_URL/*\/}
32 echo "Using $OPNFV_ARTIFACT for deployment"
35 echo "Downloading the $INSTALLER_TYPE artifact using URL http://$OPNFV_ARTIFACT_URL"
36 echo "This could take some time..."
37 echo "--------------------------------------------------------"
41 curl -s -o $WORKSPACE/opnfv.bin http://$OPNFV_ARTIFACT_URL > gsutil.bin.log 2>&1
44 ls -al $WORKSPACE/opnfv.bin
47 echo "--------------------------------------------------------"