Merge "Csit-Honeycomb job for 17.01"
[ci-management.git] / jjb / hc2vpp / include-raw-hc2vpp-csit-integration.sh
1 #!/bin/bash
2 set -xeu -o pipefail
3
4 # Clone csit and start tests
5 if [ ${STREAM} == 'master' ]; then
6     git clone https://gerrit.fd.io/r/csit --branch master
7 else
8         git clone https://gerrit.fd.io/r/csit --branch 'rls'${STREAM}
9
10 # If the git clone fails, complain clearly and exit
11 if [ $? != 0 ]; then
12     echo "Failed to run: git clone https://gerrit.fd.io/r/csit --branch master"
13     exit
14 fi
15
16 cd csit
17 # execute csit bootstrap script if it exists
18 if [ ! -e bootstrap-hc2vpp-integration.sh ]
19 then
20     echo 'ERROR: No bootstrap-hc2vpp-integration.sh found'
21     exit 1
22 else
23     # make sure that bootstrap.sh is executable
24     chmod +x bootstrap-hc2vpp-integration.sh
25     # run the script
26     if [ ${STREAM} == 'master' ]; then
27         ./bootstrap-hc2vpp-integration.sh ${STREAM}
28     else
29         ./bootstrap-hc2vpp-integration.sh 'stable.'${STREAM}
30     fi
31 fi
32
33 # vim: ts=4 ts=4 sts=4 et :