ONOS-7770 Install Bazel in p4vm
Change-Id: I3e1540bd4d080655047e3fb6accac9bec21de484
diff --git a/tools/dev/p4vm/root-bootstrap.sh b/tools/dev/p4vm/root-bootstrap.sh
index 907a372..9a1d4e9 100755
--- a/tools/dev/p4vm/root-bootstrap.sh
+++ b/tools/dev/p4vm/root-bootstrap.sh
@@ -3,6 +3,8 @@
VM_TYPE=${1:-dev}
+BAZEL_VER="0.15.2"
+BAZEL_DEB="bazel_${BAZEL_VER}-linux-x86_64.deb"
# Create user sdn
useradd -m -d /home/sdn -s /bin/bash sdn
echo "sdn:rocks" | chpasswd
@@ -20,6 +22,9 @@
EOF
fi
+# Bazel
+wget https://github.com/bazelbuild/bazel/releases/download/${BAZEL_VER}/${BAZEL_DEB}
+
# Java 8
apt-get install software-properties-common -y
add-apt-repository ppa:webupd8team/java -y
@@ -29,6 +34,7 @@
echo "oracle-java8-installer shared/accepted-oracle-license-v1-1 select true" | debconf-set-selections
apt-get -y --no-install-recommends install \
+ ./${BAZEL_DEB} \
avahi-daemon \
bridge-utils \
git \
@@ -44,8 +50,9 @@
vlan \
ntp \
vim nano emacs \
- arping \
+ arping
+rm -f ${BAZEL_DEB}
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python2.7 get-pip.py --force-reinstall