blob: c7f6c0ea2cb276b243863e563a9bfa0cd17e1cd8 [file] [log] [blame]
#!/bin/bash -ex
# exit on errors
set -eu -o pipefail
# set up ONOS build environment
ONOS_ROOT=`pwd`
. tools/build/envDefaults
if [ ${GERRIT_BRANCH} == "onos-1.14" ]
then
curl -L -o bazel.sh https://github.com/bazelbuild/bazel/releases/download/0.15.2/bazel-0.15.2-installer-linux-x86_64.sh
fi
if [ ${GERRIT_BRANCH} == "onos-1.15" ]
then
curl -L -o bazel.sh https://github.com/bazelbuild/bazel/releases/download/0.17.1/bazel-0.17.1-installer-linux-x86_64.sh
fi
if [ ${GERRIT_BRANCH} == "master" ]
then
curl -L -o bazel.sh https://github.com/bazelbuild/bazel/releases/download/0.19.0/bazel-0.19.0-installer-linux-x86_64.sh
fi
chmod +x bazel.sh
./bazel.sh --user
PATH=$PATH:/home/jenkins/bin
# import GPG key
gpg --import jenkins.key
# run the verification build - versions don't matter here, artifacts are never published
onos-build-and-upload 1.12.0-testbuild 1.12-SNAPSHOT master --dry-run