blob: f55e68a242dd8bfcc816c6ae41b72f02b03d43e9 [file] [log] [blame]
Ed Warnickecb9cada2015-12-08 15:45:58 -07001
2# Standard update + upgrade dance
3yum check-update
4yum update -y
5
6# Install build tools
7yum groupinstall 'Development Tools' -y
8yum install openssl-devel -y
9yum install glibc-static -y
10
11# Install jdk and maven
12yum install -y java-1.8.0-openjdk-devel
13
14# Load the uio kernel module
15modprobe uio_pci_generic
16
17echo uio_pci_generic >> /etc/modules-load.d/uio_pci_generic.conf
18
19# Setup for hugepages using upstart so it persists across reboots
20sysctl -w vm.nr_hugepages=1024
21echo "vm.nr_hugepages=1024" >> /etc/sysctl.conf
22mkdir -p /mnt/huge
23echo "hugetlbfs /mnt/huge hugetlbfs defaults 0 0" >> /etc/fstab
24mount /mnt/huge
25
26# Setup the vpp code
27cd ~vagrant/
28sudo -u vagrant mkdir git
29cd git/
30
Keith Burns (alagalah)d5201c82016-01-31 21:15:27 +010031# Check if git exists and remove it before attempting clone, else clone ineffective when "reload --provision"
32[ -d vpp ] && rm -rf vpp
Ed Warnickecb9cada2015-12-08 15:45:58 -070033sudo -H -u vagrant git clone /vpp
34cd vpp
35
36# Initial vpp build
37if [ -d build-root ]; then
38 # Bootstrap vpp
39 cd build-root/
40 sudo -H -u vagrant ./bootstrap.sh
41
42 # Build vpp
43 sudo -H -u vagrant make PLATFORM=vpp TAG=vpp_debug install-packages
44 cd ~vagrant/
45 cat /vagrant/README
46fi