Upgrade ufw-docker-agent image to Ubuntu 20.04 & Docker 19.03.12

This commit is contained in:
Chai Feng 2020-08-12 13:33:24 +08:00
parent 173f9659d7
commit e12810d055
2 changed files with 14 additions and 7 deletions

View file

@ -1,5 +1,8 @@
FROM ubuntu:18.04
FROM ubuntu:20.04
ARG docker_version="19.03.12"
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update \
&& apt-get install -y --no-install-recommends apt-transport-https \
ca-certificates curl software-properties-common gnupg dirmngr \
@ -7,7 +10,10 @@ RUN apt-get update \
&& add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) stable" \
&& apt-get update \
&& apt-get install -y --no-install-recommends ufw "docker-ce=18.06.1~*" \
&& apt-get install -y --no-install-recommends locales ufw \
&& ( apt-get install -y --no-install-recommends "docker-ce=5:${docker_version}~*" || \
apt-get install -y --no-install-recommends "docker-ce=${docker_version}~*" ) \
&& locale-gen en_US.UTF-8 \
&& apt-get clean autoclean \
&& apt-get autoremove --yes \
&& rm -rf /var/lib/{apt,dpkg,cache,log}/