-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile-SPGWU
40 lines (29 loc) · 1.97 KB
/
Dockerfile-SPGWU
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
FROM ubuntu:16.04
MAINTAINER Woojoong Kim <[email protected] or [email protected]>
RUN apt-get update && apt-get install curl build-essential git unzip libpcap0.8-dev gcc libjson0-dev make libc6 libc6-dev g++-multilib libzmq3-dev libcurl4-openssl-dev libssl-dev python python-pip linux-headers-$(uname -r) kmod -y
RUN apt-get install net-tools iputils-ping tcpdump vim-tiny gdb curl wget gawk -y
RUN pip install zmq
RUN git clone https://github.com/omec-project/ngic-rtc.git /opt/ngic
RUN cd /opt/ngic && git pull origin pull/32/head
# Install DPDK
RUN cd /opt/ngic && wget --no-check-certificate https://fast.dpdk.org/rel/dpdk-18.02.tar.gz && tar -zxvf dpdk-18.02.tar.gz && rm -f dpdk-18.02.tar.gz
RUN mv /opt/ngic/dpdk-*/ /opt/ngic/dpdk/
RUN cd /opt/ngic && patch ./dpdk/drivers/net/i40e/i40e_rxtx.c ./patches/avx_not_suported.patch
RUN cd /opt/ngic && cp -f dpdk-18.02_common_linuxapp dpdk/config/common_linuxapp
RUN cd /opt/ngic/dpdk && sed -ri 's,(IGB_UIO=).*,\1n,' config/common_linuxapp && sed -ri 's,(KNI_KMOD=).*,\1n,' config/common_linuxapp
RUN cd /opt/ngic/dpdk && make -j 20 install T=x86_64-native-linuxapp-gcc
# Install Hyperscan
RUN apt-get install libboost-all-dev -y
RUN apt-get install cmake ragel -y
RUN cd /opt/ngic && wget https://github.com/01org/hyperscan/archive/v4.1.0.tar.gz && tar -xvf v4.1.0.tar.gz
RUN cd /opt/ngic/hyperscan-4.1.0 && mkdir build && cd build && cmake -DCMAKE_CXX_COMPILER=c++ .. && cmake --build .
ENV LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/ngic/hyperscan-4.1.0/build/lib
ENV HYPERSCANDIR /opt/ngic/hyperscan-4.1.0
RUN cd /opt/ngic && echo "export HYPERSCANDIR=/opt/ngic/hyperscan-4.1.0" >> setenv.sh
RUN cd /opt/ngic/ && git clone --branch sgx_1.9 https://github.com/intel/linux-sgx.git
ENV RTE_SDK /opt/ngic/dpdk
RUN cd /opt/ngic && . ./setenv.sh && make clean && make -j5 build-lib && make -j4 build-dp
RUN cd /opt/ngic && . ./setenv.sh && cd dp && make clean && make EXTRA_CFLAGS='-DUSE_AF_PACKET'
WORKDIR /opt
EXPOSE 22 20
RUN ["/bin/bash"]