X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=packer%2Fprovision%2Fmininet-ovs-2.5.sh;h=7cbab296ab9cee1c07585a76dd5797c42693b4e1;hb=d48389de8ee2120e9b7b067beb5afb5aa0355fb5;hp=7fc2018a9bafdc1657bd0a920dc7cbaaf6e5cce1;hpb=fba96864189becc0c55ff1ee61572e012f507f6f;p=releng%2Fbuilder.git diff --git a/packer/provision/mininet-ovs-2.5.sh b/packer/provision/mininet-ovs-2.5.sh index 7fc2018a9..7cbab296a 100644 --- a/packer/provision/mininet-ovs-2.5.sh +++ b/packer/provision/mininet-ovs-2.5.sh @@ -1,7 +1,10 @@ -#!/bin/bash +#!/bin/bash -x # vim: sw=4 ts=4 sts=4 et tw=72 : +# force any errors to cause the script and job to end in failure +set -xeu -o pipefail + # Ensure that necessary variables are set to enable noninteractive mode in # commands. export DEBIAN_FRONTEND=noninteractive @@ -13,26 +16,37 @@ export DEBIAN_FRONTEND=noninteractive echo 'PS1="[\u@\h \W]> "' >> /etc/skel/.bashrc echo '---> Install OpenVSwitch 2.5.0' -add-apt-repository -y ppa:sgauthier/openvswitch-dpdk -apt-get update -y --force-yes -apt-get install -y --force-yes openvswitch-switch - -echo '---> Installing mininet 2.2.2' -git clone git://github.com/mininet/mininet -cd mininet -git checkout -b 2.2.2 2.2.2 -cd .. -mininet/util/install.sh -nf - -echo '---> Installing MT-Cbench' -apt-get install -y --force-yes build-essential snmp libsnmp-dev snmpd libpcap-dev \ +apt-get update -m +apt-get install openvswitch-switch openvswitch-vtep + +# Temporary workaround required to bring up OVS +# post-install without which OVS daemon exits. +service openvswitch-switch restart +# Verify the OVS service status +service openvswitch-switch status + +echo '---> Installing mininet' +apt-get install mininet + +echo '---> Installing build pre-requisites' +apt-get install build-essential snmp libsnmp-dev snmpd libpcap-dev \ autoconf make automake libtool libconfig-dev libssl-dev libffi-dev libssl-doc pkg-config + git clone https://github.com/intracom-telecom-sdn/mtcbench.git -mtcbench/build_mtcbench.sh -cp mtcbench/oflops/cbench/cbench /usr/local/bin/ +mtcbench/deploy/docker/provision.sh +# TODO: remove workaround for build issue with mtcbench +# when mtcbench dependency build correctly +# https://github.com/intracom-telecom-sdn/mtcbench/issues/10 +mtcbench/build_mtcbench.sh || true +cd mtcbench/oflops/cbench +make +cp cbench /usr/local/bin/ echo '---> Installing exabgp' -apt-get install -y --force-yes exabgp +apt-get install exabgp + +# Install vlan for vlan based tests in VTN suites +apt-get install vlan -echo '---> All Python package installation should happen in virtualenv' -apt-get install -y --force-yes python-virtualenv python-pip +# Install netaddr package which is needed by some custom mininet topologies +apt-get install python-netaddr