ctwo.provision.sh revision 58fda365
1#!/usr/bin/env bash
2# Copyright (c) 2016 Intel Corporation
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at:
6#
7#     http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14
15VPP_DIR=~/vpp
16VPP_GIT="https://git.fd.io/vpp"
17#PLATFORM=vpp_lite
18PLATFORM=vpp
19
20echo Cloning $VPP_GIT
21git clone $VPP_GIT $VPP_DIR
22
23# Install dependencies
24echo Building $VPP_DIR
25cd $VPP_DIR
26make UNATTENDED=yes install-dep
27
28make wipe
29(cd build-root/; make distclean)
30rm -f build-root/.bootstrap.ok
31
32# Build and install packaging
33make PLATFORM=$PLATFORM bootstrap
34make PLATFORM=$PLATFORM pkg-deb
35
36# Install VPPP
37(cd ${VPP_DIR}/build-root/;sudo dpkg -i *.deb)
38
39sudo sed -i 's/dpdk {/dpdk {\n\tno-pci\n/' /etc/vpp/startup.conf
40sudo service vpp start
41