upgrade to python3 libraries
[testsuite.git] / docker / Dockerfile
index 871e849..723158a 100644 (file)
@@ -1,39 +1,60 @@
 FROM ubuntu
 ## Be careful of Windows newlines
 
-MAINTAINER "OpenECOMP"
+MAINTAINER "ONAP"
 
-LABEL name="Docker image for the OpenECOMP Robot Testing Framework"
+LABEL name="Docker image for the ONAP Robot Testing Framework"
 LABEL usage="docker run -e ROBOT_TEST=<testname> -ti openecompete"
 
-# Install Python Pip, Robot framework, firefox, lighttpd web server, wget
-RUN apt-get update && \
-    apt-get --assume-yes install python=2.7.11-1 && \
-    apt-get --assume-yes install build-essential dbus dnsutils git libappindicator1 \
-                                libffi-dev libindicator7 libssl-dev libxss1 \
-                                lighttpd net-tools python-dev python-pip unzip \
-                                wget xvfb && \
-    pip install --upgrade pip && \
-    pip install robotframework && \
-    python --version
-
-# Install chrome
-RUN wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - && \
-    echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list  && \
-    apt-get update && \
-    apt-get --assume-yes install google-chrome-stable
+ENV BUILDTIME=true
+
+# Install Python, Pip, Robot framework, chromium, lighttpd web server
+RUN apt-get update \
+    && apt-get install \
+        --no-install-recommends \
+        --assume-yes \
+            chromium-browser \
+            chromium-chromedriver \
+            dnsutils \
+            git \
+            gcc \
+            libffi-dev \
+            libssl-dev \
+            lighttpd \
+            make \
+            net-tools \
+            python2.7 \
+            python-dev \
+            python-setuptools \
+            python-wheel \
+            python-pip \
+            unzip \
+            x11-utils \
+            x11-xserver-utils \
+            xvfb \
+            xxd  \
+            vim
+            
+
+RUN pip install robotframework==3.1.1 \
+    && python --version
 
 # Copy the robot code
-COPY / /var/opt/OpenECOMP_ETE/
+COPY . /var/opt/ONAP/
 COPY lighttpd.conf /etc/lighttpd/lighttpd.conf
-RUN chmod 777 /var/opt/OpenECOMP_ETE/setup.sh && \
-    chmod 777 /var/opt/OpenECOMP_ETE/runTags.sh && \
-    chmod 777 /var/opt/OpenECOMP_ETE/dnstraffic.sh && \
-    chmod 777 /var/opt/OpenECOMP_ETE/runSoak.sh && \
-    chmod 777 /var/opt/OpenECOMP_ETE/runEteTag.sh
-
-# Update the ssh library so that it will run properly in the docker env
-RUN cd /var/opt/OpenECOMP_ETE && ./setup.sh && apt-get clean
+COPY authorization /etc/lighttpd/authorization
+RUN chmod 777 /var/opt/ONAP/setup.sh \
+    && chmod 777 /var/opt/ONAP/runTags.sh \
+    && chmod 777 /var/opt/ONAP/dnstraffic.sh \
+    && chmod 777 /var/opt/ONAP/runSoak.sh \
+    && chmod 777 /var/opt/ONAP/runEteTag.sh \
+    && chmod 600 /var/opt/ONAP/robot/assets/keys/* 
+
+RUN cd /var/opt/ONAP \
+    && ./setup.sh \
+    && apt-get autoremove --assume-yes \
+    && rm -rf /var/lib/apt/lists/*  \
+    && apt-get clean
 
 CMD ["lighttpd", "-D", "-f",  "/etc/lighttpd/lighttpd.conf"]