forked from opencomputeproject/SAI-Challenger
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile.client
54 lines (42 loc) · 1.92 KB
/
Dockerfile.client
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
FROM debian:buster-slim
MAINTAINER [email protected]
RUN echo "deb [arch=amd64] http://debian-archive.trafficmanager.net/debian/ buster main contrib non-free" >> /etc/apt/sources.list && \
echo "deb-src [arch=amd64] http://debian-archive.trafficmanager.net/debian/ buster main contrib non-free" >> /etc/apt/sources.list && \
echo "deb [arch=amd64] http://debian-archive.trafficmanager.net/debian-security/ buster/updates main contrib non-free" >> /etc/apt/sources.list && \
echo "deb-src [arch=amd64] http://debian-archive.trafficmanager.net/debian-security/ buster/updates main contrib non-free" >> /etc/apt/sources.list && \
echo "deb [arch=amd64] http://debian-archive.trafficmanager.net/debian buster-backports main" >> /etc/apt/sources.list
## Make apt-get non-interactive
ENV DEBIAN_FRONTEND=noninteractive
# Install generic packages
RUN apt-get -o Acquire::Check-Valid-Until=false update && apt-get install -y \
apt-utils \
procps \
build-essential \
python3 \
python3-pip \
python3-redis \
iproute2 \
rsyslog \
supervisor
RUN pip3 install pytest pytest_dependency pytest-html
# Install PTF dependencies
RUN pip3 install scapy
# Install ptf_nn_agent dependencies
RUN apt-get install -y libffi-dev cmake wget \
&& wget https://github.com/nanomsg/nanomsg/archive/1.0.0.tar.gz \
&& tar xvfz 1.0.0.tar.gz \
&& cd nanomsg-1.0.0 \
&& mkdir -p build \
&& cd build \
&& cmake .. \
&& make install \
&& ldconfig \
&& cd ../.. \
&& rm -rf 1.0.0.tar.gz nanomsg-1.0.0 \
&& pip3 install nnpy
# Disable kernel logging support
RUN sed -ri '/imklog/s/^/#/' /etc/rsyslog.conf
COPY scripts/client/supervisord.conf /etc/supervisor/conf.d/supervisord.conf
COPY scripts/veth-create.sh /usr/bin/veth-create.sh
WORKDIR /sai-challenger/tests
CMD ["/usr/bin/supervisord"]