summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYasufumi Ogawa <ogawa.yasufumi@lab.ntt.co.jp>2018-06-15 17:37:41 +0900
committerFerruh Yigit <ferruh.yigit@intel.com>2018-08-15 17:32:44 +0100
commitc9a9134ce5e774bb726cbb90912e6e9a1370196a (patch)
treecf95e92c68b5873058417c8de03666b8462fbe49
parent7e048f5017802b3f27f9de4aba47dd59523235b1 (diff)
downloadspp-c9a9134ce5e774bb726cbb90912e6e9a1370196a.zip
spp-c9a9134ce5e774bb726cbb90912e6e9a1370196a.tar.gz
spp-c9a9134ce5e774bb726cbb90912e6e9a1370196a.tar.xz
tools/sppc: add dockerfiles for DPDK
Add Dockerfiles for installing DPDK on Ubuntu image. The number of versions means the versions of distribution. Build tool understand that which of Dockerfile should be used with given options. Signed-off-by: Yasufumi Ogawa <ogawa.yasufumi@lab.ntt.co.jp>
-rw-r--r--.gitignore1
-rw-r--r--tools/sppc/build/ubuntu/dpdk/Dockerfile.16.0444
-rw-r--r--tools/sppc/build/ubuntu/dpdk/Dockerfile.18.0444
-rw-r--r--tools/sppc/build/ubuntu/dpdk/Dockerfile.latest44
4 files changed, 133 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e2c6c1e..ff9ba64 100644
--- a/.gitignore
+++ b/.gitignore
@@ -3,3 +3,4 @@
*.log
docs/guides/_build/*
src/controller/3rd_party/*
+tools/sppc/build/*/*/env.sh
diff --git a/tools/sppc/build/ubuntu/dpdk/Dockerfile.16.04 b/tools/sppc/build/ubuntu/dpdk/Dockerfile.16.04
new file mode 100644
index 0000000..b4b3681
--- /dev/null
+++ b/tools/sppc/build/ubuntu/dpdk/Dockerfile.16.04
@@ -0,0 +1,44 @@
+FROM ubuntu:16.04
+
+ARG rte_sdk
+ARG rte_target
+ARG home_dir
+ARG dpdk_repo
+ARG dpdk_branch
+
+ENV PATH ${rte_sdk}/${rte_target}/app:${PATH}
+ENV http_proxy ${http_proxy}
+ENV https_proxy $https_proxy
+ENV no_proxy ${no_proxy}
+ENV RTE_SDK ${rte_sdk}
+ENV RTE_TARGET ${rte_target}
+
+
+RUN apt-get update && apt-get install -y \
+ git \
+ gcc \
+ python \
+ pciutils \
+ make \
+ libnuma-dev \
+ gcc-multilib \
+ libarchive-dev \
+ linux-headers-$(uname -r) \
+ libpcap-dev \
+ pkg-config \
+ && apt-get clean \
+ && rm -rf /var/lib/apt/lists/*
+
+WORKDIR $home_dir
+RUN git clone $dpdk_branch $dpdk_repo
+
+# Compile DPDK
+WORKDIR $rte_sdk
+RUN make install T=$rte_target
+RUN make app T=$rte_target
+RUN make examples T=$rte_target
+
+# Set working directory when container is launched
+WORKDIR ${home_dir}
+ADD env.sh ${home_dir}/env.sh
+RUN echo "source ${home_dir}/env.sh" >> ${home_dir}/.bashrc
diff --git a/tools/sppc/build/ubuntu/dpdk/Dockerfile.18.04 b/tools/sppc/build/ubuntu/dpdk/Dockerfile.18.04
new file mode 100644
index 0000000..16fcf39
--- /dev/null
+++ b/tools/sppc/build/ubuntu/dpdk/Dockerfile.18.04
@@ -0,0 +1,44 @@
+FROM ubuntu:18.04
+
+ARG rte_sdk
+ARG rte_target
+ARG home_dir
+ARG dpdk_repo
+ARG dpdk_branch
+
+ENV PATH ${rte_sdk}/${rte_target}/app:${PATH}
+ENV http_proxy ${http_proxy}
+ENV https_proxy $https_proxy
+ENV no_proxy ${no_proxy}
+ENV RTE_SDK ${rte_sdk}
+ENV RTE_TARGET ${rte_target}
+
+
+RUN apt-get update && apt-get install -y \
+ git \
+ gcc \
+ python \
+ pciutils \
+ make \
+ libnuma-dev \
+ gcc-multilib \
+ libarchive-dev \
+ linux-headers-$(uname -r) \
+ libpcap-dev \
+ pkg-config \
+ && apt-get clean \
+ && rm -rf /var/lib/apt/lists/*
+
+WORKDIR $home_dir
+RUN git clone $dpdk_branch $dpdk_repo
+
+# Compile DPDK
+WORKDIR $rte_sdk
+RUN make install T=$rte_target
+RUN make app T=$rte_target
+RUN make examples T=$rte_target
+
+# Set working directory when container is launched
+WORKDIR ${home_dir}
+ADD env.sh ${home_dir}/env.sh
+RUN echo "source ${home_dir}/env.sh" >> ${home_dir}/.bashrc
diff --git a/tools/sppc/build/ubuntu/dpdk/Dockerfile.latest b/tools/sppc/build/ubuntu/dpdk/Dockerfile.latest
new file mode 100644
index 0000000..832b0e2
--- /dev/null
+++ b/tools/sppc/build/ubuntu/dpdk/Dockerfile.latest
@@ -0,0 +1,44 @@
+FROM ubuntu:latest
+
+ARG rte_sdk
+ARG rte_target
+ARG home_dir
+ARG dpdk_repo
+ARG dpdk_branch
+
+ENV PATH ${rte_sdk}/${rte_target}/app:${PATH}
+ENV http_proxy ${http_proxy}
+ENV https_proxy $https_proxy
+ENV no_proxy ${no_proxy}
+ENV RTE_SDK ${rte_sdk}
+ENV RTE_TARGET ${rte_target}
+
+
+RUN apt-get update && apt-get install -y \
+ git \
+ gcc \
+ python \
+ pciutils \
+ make \
+ libnuma-dev \
+ gcc-multilib \
+ libarchive-dev \
+ linux-headers-$(uname -r) \
+ libpcap-dev \
+ pkg-config \
+ && apt-get clean \
+ && rm -rf /var/lib/apt/lists/*
+
+WORKDIR $home_dir
+RUN git clone $dpdk_branch $dpdk_repo
+
+# Compile DPDK
+WORKDIR $rte_sdk
+RUN make install T=$rte_target
+RUN make app T=$rte_target
+RUN make examples T=$rte_target
+
+# Set working directory when container is launched
+WORKDIR ${home_dir}
+ADD env.sh ${home_dir}/env.sh
+RUN echo "source ${home_dir}/env.sh" >> ${home_dir}/.bashrc