6 echo "Uploading the $INSTALLER_TYPE artifact. This could take some time..."
7 echo "--------------------------------------------------------"
10 # source the opnfv.properties to get ARTIFACT_VERSION
11 source $BUILD_DIRECTORY/opnfv.properties
13 # clone releng repository
14 echo "Cloning releng repository..."
15 [ -d releng ] && rm -rf releng
16 git clone https://gerrit.opnfv.org/gerrit/releng $WORKSPACE/releng/ &> /dev/null
17 #this is where we import the siging key
18 if [ -f $WORKSPACE/releng/utils/gpg_import_key.sh ]; then
19 source $WORKSPACE/releng/utils/gpg_import_key.sh
23 time gpg2 -vvv --batch --yes --no-tty \
24 --default-key opnfv-helpdesk@rt.linuxfoundation.org \
25 --passphrase besteffort \
26 --detach-sig $BUILD_DIRECTORY/compass.iso
28 gsutil cp $BUILD_DIRECTORY/compass.iso.sig gs://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.iso.sig
29 echo "ISO signature Upload Complete!"
34 # upload artifact and additional files to google storage
35 gsutil cp $BUILD_DIRECTORY/compass.iso gs://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.iso > gsutil.iso.log 2>&1
36 gsutil cp $BUILD_DIRECTORY/opnfv.properties gs://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.properties > gsutil.properties.log 2>&1
37 gsutil cp $BUILD_DIRECTORY/opnfv.properties gs://$GS_URL/latest.properties > gsutil.latest.log 2>&1
40 -h "Content-Type:text/html" \
41 -h "Cache-Control:private, max-age=0, no-transform" \
42 gs://$GS_URL/latest.properties \
43 gs://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.properties > /dev/null 2>&1
46 -h "Cache-Control:private, max-age=0, no-transform" \
47 gs://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.iso > /dev/null 2>&1
49 # disabled errexit due to gsutil setmeta complaints
50 # BadRequestException: 400 Invalid argument
51 # check if we uploaded the file successfully to see if things are fine
52 gsutil ls gs://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.iso > /dev/null 2>&1
53 if [[ $? -ne 0 ]]; then
54 echo "Problem while uploading artifact!"
55 echo "Check log $WORKSPACE/gsutil.iso.log on the machine where this build is done."
60 echo "--------------------------------------------------------"
62 echo "Artifact is available as http://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.iso"