From 6f591ee7740575101a455d06b151bbbfe68c9317 Mon Sep 17 00:00:00 2001 From: Callum Tait <15716903+toast-gear@users.noreply.github.com> Date: Mon, 7 Feb 2022 20:10:02 +0000 Subject: [PATCH] chore: bump docker version (#1094) * chore: bump docker version Co-authored-by: toast-gear --- .github/workflows/runners.yml | 2 +- runner/Dockerfile | 2 +- runner/Dockerfile.dindrunner | 2 +- runner/Dockerfile.ubuntu.1804 | 105 ---------------------------------- runner/Makefile | 2 +- 5 files changed, 4 insertions(+), 109 deletions(-) delete mode 100644 runner/Dockerfile.ubuntu.1804 diff --git a/.github/workflows/runners.yml b/.github/workflows/runners.yml index 20d11104..ec270137 100644 --- a/.github/workflows/runners.yml +++ b/.github/workflows/runners.yml @@ -16,7 +16,7 @@ on: env: RUNNER_VERSION: 2.287.1 - DOCKER_VERSION: 20.10.8 + DOCKER_VERSION: 20.10.12 DOCKERHUB_USERNAME: summerwind jobs: diff --git a/runner/Dockerfile b/runner/Dockerfile index ae7edca4..d6562771 100644 --- a/runner/Dockerfile +++ b/runner/Dockerfile @@ -3,7 +3,7 @@ FROM ubuntu:20.04 ARG TARGETPLATFORM ARG RUNNER_VERSION=2.287.1 ARG DOCKER_CHANNEL=stable -ARG DOCKER_VERSION=20.10.8 +ARG DOCKER_VERSION=20.10.12 ARG DUMB_INIT_VERSION=1.2.5 RUN test -n "$TARGETPLATFORM" || (echo "TARGETPLATFORM must be set" && false) diff --git a/runner/Dockerfile.dindrunner b/runner/Dockerfile.dindrunner index 47bd2655..19d9bfe2 100644 --- a/runner/Dockerfile.dindrunner +++ b/runner/Dockerfile.dindrunner @@ -3,7 +3,7 @@ FROM ubuntu:20.04 ARG TARGETPLATFORM ARG RUNNER_VERSION=2.287.1 ARG DOCKER_CHANNEL=stable -ARG DOCKER_VERSION=20.10.8 +ARG DOCKER_VERSION=20.10.12 ARG DUMB_INIT_VERSION=1.2.5 RUN test -n "$TARGETPLATFORM" || (echo "TARGETPLATFORM must be set" && false) diff --git a/runner/Dockerfile.ubuntu.1804 b/runner/Dockerfile.ubuntu.1804 deleted file mode 100644 index 45502964..00000000 --- a/runner/Dockerfile.ubuntu.1804 +++ /dev/null @@ -1,105 +0,0 @@ -FROM ubuntu:18.04 - -ARG TARGETPLATFORM -ARG RUNNER_VERSION=2.287.1 -ARG DOCKER_CHANNEL=stable -ARG DOCKER_VERSION=20.10.8 -ARG DUMB_INIT_VERSION=1.2.5 - -RUN test -n "$TARGETPLATFORM" || (echo "TARGETPLATFORM must be set" && false) - -ENV DEBIAN_FRONTEND=noninteractive -RUN apt update -y \ - && apt install -y software-properties-common \ - && add-apt-repository -y ppa:git-core/ppa \ - && apt update -y \ - && apt install -y --no-install-recommends \ - build-essential \ - curl \ - ca-certificates \ - dnsutils \ - ftp \ - git \ - iproute2 \ - iputils-ping \ - jq \ - libunwind8 \ - locales \ - netcat \ - openssh-client \ - parallel \ - python3-pip \ - rsync \ - shellcheck \ - sudo \ - telnet \ - time \ - tzdata \ - unzip \ - upx \ - wget \ - zip \ - zstd \ - && ln -sf /usr/bin/python3 /usr/bin/python \ - && ln -sf /usr/bin/pip3 /usr/bin/pip \ - && rm -rf /var/lib/apt/lists/* - -# arch command on OS X reports "i386" for Intel CPUs regardless of bitness -RUN export ARCH=$(echo ${TARGETPLATFORM} | cut -d / -f2) \ - && if [ "$ARCH" = "arm64" ]; then export ARCH=aarch64 ; fi \ - && if [ "$ARCH" = "amd64" ] || [ "$ARCH" = "i386" ]; then export ARCH=x86_64 ; fi \ - && curl -f -L -o /usr/local/bin/dumb-init https://github.com/Yelp/dumb-init/releases/download/v${DUMB_INIT_VERSION}/dumb-init_${DUMB_INIT_VERSION}_${ARCH} \ - && chmod +x /usr/local/bin/dumb-init - -# Docker download supports arm64 as aarch64 & amd64 / i386 as x86_64 -RUN set -vx; \ - export ARCH=$(echo ${TARGETPLATFORM} | cut -d / -f2) \ - && if [ "$ARCH" = "arm64" ]; then export ARCH=aarch64 ; fi \ - && if [ "$ARCH" = "amd64" ] || [ "$ARCH" = "i386" ]; then export ARCH=x86_64 ; fi \ - && curl -f -L -o docker.tgz https://download.docker.com/linux/static/${DOCKER_CHANNEL}/${ARCH}/docker-${DOCKER_VERSION}.tgz \ - && tar zxvf docker.tgz \ - && install -o root -g root -m 755 docker/docker /usr/local/bin/docker \ - && rm -rf docker docker.tgz \ - && adduser --disabled-password --gecos "" --uid 1000 runner \ - && groupadd docker \ - && usermod -aG sudo runner \ - && usermod -aG docker runner \ - && echo "%sudo ALL=(ALL:ALL) NOPASSWD:ALL" > /etc/sudoers - -ENV RUNNER_ASSETS_DIR=/runnertmp -ENV HOME=/home/runner - -# Runner download supports amd64 as x64. Externalstmp is needed for making mount points work inside DinD. -# -# libyaml-dev is required for ruby/setup-ruby action. -# It is installed after installdependencies.sh and before removing /var/lib/apt/lists -# to avoid rerunning apt-update on its own. -RUN export ARCH=$(echo ${TARGETPLATFORM} | cut -d / -f2) \ - && if [ "$ARCH" = "amd64" ] || [ "$ARCH" = "x86_64" ] || [ "$ARCH" = "i386" ]; then export ARCH=x64 ; fi \ - && mkdir -p "$RUNNER_ASSETS_DIR" \ - && cd "$RUNNER_ASSETS_DIR" \ - && curl -f -L -o runner.tar.gz https://github.com/actions/runner/releases/download/v${RUNNER_VERSION}/actions-runner-linux-${ARCH}-${RUNNER_VERSION}.tar.gz \ - && tar xzf ./runner.tar.gz \ - && rm runner.tar.gz \ - && ./bin/installdependencies.sh \ - && mv ./externals ./externalstmp \ - && apt-get install -y libyaml-dev \ - && rm -rf /var/lib/apt/lists/* - -ENV RUNNER_TOOL_CACHE=/opt/hostedtoolcache -RUN mkdir /opt/hostedtoolcache \ - && chgrp docker /opt/hostedtoolcache \ - && chmod g+rwx /opt/hostedtoolcache - -COPY entrypoint.sh / -COPY --chown=runner:docker patched $RUNNER_ASSETS_DIR/patched - -# Add the Python "User Script Directory" to the PATH -ENV PATH="${PATH}:${HOME}/.local/bin" -ENV ImageOS=ubuntu20 - -USER runner - -ENTRYPOINT ["/usr/local/bin/dumb-init", "--"] -CMD ["/entrypoint.sh"] - diff --git a/runner/Makefile b/runner/Makefile index 8fd82b8a..6ae921d6 100644 --- a/runner/Makefile +++ b/runner/Makefile @@ -5,7 +5,7 @@ TAG ?= latest TARGETPLATFORM ?= $(shell arch) RUNNER_VERSION ?= 2.287.1 -DOCKER_VERSION ?= 20.10.8 +DOCKER_VERSION ?= 20.10.12 # default list of platforms for which multiarch image is built ifeq (${PLATFORMS}, )