1 # Copyright (c) 2018 Cisco and/or its affiliates.
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at:
6 # http://www.apache.org/licenses/LICENSE-2.0
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 # See the License for the specific language governing permissions and
12 # limitations under the License.
14 FROM ubuntu:bionic-20180821
16 MAINTAINER csit-dev <csit-dev@lists.fd.io>
17 LABEL Description="CSIT vpp-device ubuntu 18.04 baseline image"
18 LABEL Vendor="cisco.com"
21 # Setup the environment
22 ENV DEBIAN_FRONTEND=noninteractive
23 ENV LANG='en_US.UTF-8' LANGUAGE='en_US:en' LC_ALL='en_US.UTF-8'
24 ENV NOTVISIBLE "in users profile"
25 ENV VPP_PYTHON_PREFIX=/var/cache/vpp/python
28 RUN apt-get -q update \
29 && apt-get install -y -qq \
32 software-properties-common \
33 && rm -rf /var/lib/apt/lists/*
36 RUN curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add - \
37 && add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" \
38 && apt-get remove -y \
42 RUN apt-get -q update \
43 && apt-get install -y -qq \
65 openjdk-8-jdk-headless \
85 && rm -rf /var/lib/apt/lists/*
88 RUN locale-gen en_US.UTF-8 \
89 && dpkg-reconfigure locales
92 RUN chown root:syslog /var/log \
93 && chmod 755 /etc/default
95 # Create directory structure
96 RUN mkdir -p /tmp/dumps \
97 && mkdir -p /var/cache/vpp/python \
98 && mkdir -p /var/run/sshd
111 python-dateutil==2.4.2 \
114 robotframework==2.9.2 \
123 RUN echo 'root:Csit1234' | chpasswd \
124 && sed -i 's/#PermitRootLogin prohibit-password/PermitRootLogin yes/' /etc/ssh/sshd_config \
125 && sed 's@session\s*required\s*pam_loginuid.so@session optional pam_loginuid.so@g' -i /etc/pam.d/sshd \
126 && echo "export VISIBLE=now" >> /etc/profile
130 COPY supervisord.conf /etc/supervisord/supervisord.conf
132 CMD ["sh", "-c", "rm -f /dev/shm/db /dev/shm/global_vm /dev/shm/vpe-api; /usr/bin/supervisord -c /etc/supervisord/supervisord.conf; /usr/sbin/sshd -D"]