Merge "Add jobs to build arm functest images"
[releng.git] / jjb / 3rd_party_ci / install-netvirt.sh
1 #!/bin/bash
2 set -o errexit
3 set -o nounset
4 set -o pipefail
5
6 SNAP_CACHE=$HOME/snap_cache
7 # clone opnfv sdnvpn repo
8 git clone https://gerrit.opnfv.org/gerrit/p/sdnvpn.git $WORKSPACE/sdnvpn
9
10 if [ ! -f "$NETVIRT_ARTIFACT" ]; then
11   echo "ERROR: ${NETVIRT_ARTIFACT} specified as NetVirt Artifact, but file does not exist"
12   exit 1
13 fi
14
15 # TODO (trozet) snapshot should have already been unpacked into cache folder
16 # but we really should check the cache here, and not use a single cache folder
17 # for when we support multiple jobs on a single slave
18 pushd sdnvpn/odl-pipeline/lib > /dev/null
19 ./odl_reinstaller.sh --pod-config ${SNAP_CACHE}/node.yaml \
20   --odl-artifact ${NETVIRT_ARTIFACT} --ssh-key-file ${SNAP_CACHE}/id_rsa
21 popd > /dev/null