From 3ae624cd6e945146d5ca34f02e3b54569a83d7e4 Mon Sep 17 00:00:00 2001 From: Ryan Chu Date: Mon, 19 Nov 2018 16:14:23 +0100 Subject: [PATCH] Docker Provisioning: Remove the fixed version of package dependencies MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Free the dependencies of the specific Ubuntu packages. Ensure that test server is using the latest version of the Ubuntu packages to test network changes. Otherwise, all the docker files need to be manually updated when upgrading to the next Ubuntu version (e.g. 18.04). For debugging purpose, the installed packaged will be listed in the provisioning logs. Change-Id: I38d119d11f33cfd60dc34fcd57ec0fe1615e98f2 Reviewed-by: Jędrzej Nowacki Reviewed-by: Edward Welbourne Reviewed-by: Qt CI Bot --- .../common/linux/testserver/apache2/Dockerfile | 3 ++- .../common/linux/testserver/danted/Dockerfile | 3 ++- .../common/linux/testserver/docker_testserver.sh | 11 +++++++++++ .../common/linux/testserver/ftp-proxy/Dockerfile | 3 ++- .../common/linux/testserver/squid/Dockerfile | 3 ++- .../common/linux/testserver/vsftpd/Dockerfile | 3 ++- 6 files changed, 21 insertions(+), 5 deletions(-) diff --git a/coin/provisioning/common/linux/testserver/apache2/Dockerfile b/coin/provisioning/common/linux/testserver/apache2/Dockerfile index bb2dc850..b39eb21e 100644 --- a/coin/provisioning/common/linux/testserver/apache2/Dockerfile +++ b/coin/provisioning/common/linux/testserver/apache2/Dockerfile @@ -1,5 +1,6 @@ FROM ubuntu:16.04 -RUN apt-get update && apt-get install -y apache2 libcgi-session-perl wget avahi-daemon +ARG packages="apache2 libcgi-session-perl wget avahi-daemon" +RUN apt-get update && apt-get install -y $packages && dpkg -l $packages EXPOSE 80 443 # install configurations and test data diff --git a/coin/provisioning/common/linux/testserver/danted/Dockerfile b/coin/provisioning/common/linux/testserver/danted/Dockerfile index eb2ac6ff..67c1159b 100644 --- a/coin/provisioning/common/linux/testserver/danted/Dockerfile +++ b/coin/provisioning/common/linux/testserver/danted/Dockerfile @@ -1,5 +1,6 @@ FROM ubuntu:16.04 -RUN apt-get update && apt-get install -y gdebi-core=0.9.5.7ubuntu1 wget avahi-daemon +ARG packages="gdebi-core wget avahi-daemon" +RUN apt-get update && apt-get install -y $packages && dpkg -l $packages RUN wget http://ppa.launchpad.net/dajhorn/dante/ubuntu/pool/main/d/dante/dante-server_1.4.1-1_amd64.deb RUN gdebi -n dante-server_1.4.1-1_amd64.deb EXPOSE 1080-1081 diff --git a/coin/provisioning/common/linux/testserver/docker_testserver.sh b/coin/provisioning/common/linux/testserver/docker_testserver.sh index a88e89b9..2534c416 100755 --- a/coin/provisioning/common/linux/testserver/docker_testserver.sh +++ b/coin/provisioning/common/linux/testserver/docker_testserver.sh @@ -53,6 +53,17 @@ do sha1=$(find $context -type f -print0 | sort -z | xargs -r0 sha1sum | awk '{ print $1 }' | \ sha1sum | awk '{ print $1 }') sudo docker build -t qt-test-server-$server:$sha1 $context + + # transition - The fixed tag is temporarily used by CI to pass the qtbase testing. + case $server in + apache2) fixed_tag="cc9ea678b92bdda33acb9fa0159bb4ad0f3cd947" ;; + squid) fixed_tag="577d99307eea9a8cccfec944d25be2bce2fe99cc" ;; + vsftpd) fixed_tag="18896604c7e90b543e56d80c8a8aabdb65a590d0" ;; + ftp-proxy) fixed_tag="2c6c8f1ab6a364b540c43d705fb6f15a585cb2af" ;; + danted) fixed_tag="327dd56c3c35db85b26fac93213a5a1918475bc7" ;; + esac + [ -z "$fixed_tag" ] || \ + sudo docker tag qt-test-server-$server:$sha1 qt-test-server-$server:$fixed_tag done sudo docker images diff --git a/coin/provisioning/common/linux/testserver/ftp-proxy/Dockerfile b/coin/provisioning/common/linux/testserver/ftp-proxy/Dockerfile index cecb2dca..c719c1eb 100644 --- a/coin/provisioning/common/linux/testserver/ftp-proxy/Dockerfile +++ b/coin/provisioning/common/linux/testserver/ftp-proxy/Dockerfile @@ -1,3 +1,4 @@ FROM ubuntu:16.04 -RUN apt-get update && apt-get install -y ftp-proxy=1.9.2.4-10 avahi-daemon +ARG packages="ftp-proxy avahi-daemon" +RUN apt-get update && apt-get install -y $packages && dpkg -l $packages EXPOSE 2121 diff --git a/coin/provisioning/common/linux/testserver/squid/Dockerfile b/coin/provisioning/common/linux/testserver/squid/Dockerfile index 0b930bca..f0ed68b3 100644 --- a/coin/provisioning/common/linux/testserver/squid/Dockerfile +++ b/coin/provisioning/common/linux/testserver/squid/Dockerfile @@ -1,3 +1,4 @@ FROM ubuntu:16.04 -RUN apt-get update && apt-get install -y squid=3.5.12-1ubuntu7.5 avahi-daemon +ARG packages="squid avahi-daemon" +RUN apt-get update && apt-get install -y $packages && dpkg -l $packages EXPOSE 3128-3130 diff --git a/coin/provisioning/common/linux/testserver/vsftpd/Dockerfile b/coin/provisioning/common/linux/testserver/vsftpd/Dockerfile index f8e32d40..af6cd7c7 100644 --- a/coin/provisioning/common/linux/testserver/vsftpd/Dockerfile +++ b/coin/provisioning/common/linux/testserver/vsftpd/Dockerfile @@ -1,5 +1,6 @@ FROM ubuntu:16.04 -RUN apt-get update && apt-get install -y vsftpd=3.0.3-3ubuntu2 ftp=0.17-33 wget avahi-daemon +ARG packages="vsftpd ftp wget avahi-daemon" +RUN apt-get update && apt-get install -y $packages && dpkg -l $packages EXPOSE 20-21 # install configurations and test data