Use GS_URL as it is now defined by Jenkins and detect Jenkins job name
[ovsnfv.git] / ci / upload_artifacts.sh
1 #!/bin/bash
2 set -o errexit
3 set -o nounset
4 set -o pipefail
5
6 # log info to console
7 echo "Uploading the OVS $VERSION RPM artifacts. "
8 echo "-----------------------------------------"
9 echo
10
11 export RPMFILE_D=openvswitch-debuginfo-$VERSION-1.x86_64.rpm
12 export RPMFILE=openvswitch-$VERSION-1.x86_64.rpm
13
14 # upload artifact and additional files to google storage
15 echo gsutil cp $TMP_RELEASE_DIR/$RPMFILE_D $GS_URL/opnfv-$DATE-$RPMFILE_D
16 gsutil cp $TMP_RELEASE_DIR/$RPMFILE_D $GS_URL/opnfv-$DATE-$RPMFILE_D
17
18 echo gsutil cp $TMP_RELEASE_DIR/$RPMFILE $GS_URL/opnfv-$DATE-$RPMFILE
19 gsutil cp $TMP_RELEASE_DIR/$RPMFILE $GS_URL/opnfv-$DATE-$RPMFILE
20
21 echo
22 echo "------------------------------------------------------"
23 echo "Done!"
24 echo "Artifacts are available as $GS_URL/opnfv-$DATE-$RPMFILE"