From 6a77ef2170b64415b0d9ff487ee87be60da3eed8 Mon Sep 17 00:00:00 2001 From: Mike McQuaid Date: Fri, 24 Mar 2023 08:57:48 +0000 Subject: [PATCH] docker: stop building Ubuntu 16.04 image. This is too slow to be building every time and we're long past the deprecation date. Fixes https://github.com/Homebrew/brew/issues/14661 --- .github/workflows/docker.yml | 2 +- .github/workflows/tests.yml | 24 ------------------------ Dockerfile | 2 +- docs/Linux-CI.md | 5 +++-- 4 files changed, 5 insertions(+), 28 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index 9c1c84b332..fc22973764 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -22,7 +22,7 @@ jobs: strategy: fail-fast: false matrix: - version: ["16.04", "18.04", "20.04", "22.04"] + version: ["18.04", "20.04", "22.04"] steps: - name: Checkout uses: actions/checkout@main diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 753b55289e..b73449bc76 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -189,30 +189,6 @@ jobs: docker tag brew "homebrew/ubuntu22.04:master" docker push "homebrew/ubuntu22.04:master" - - name: Build deprecated 16.04 Docker image - if: github.ref == 'refs/heads/master' - working-directory: ${{ steps.set-up-homebrew.outputs.repository-path }} - run: | - echo "homebrew/ubuntu16.04:master is deprecated and will soon be retired. Use homebrew/ubuntu22.04:master or homebrew/ubuntu18.04 or homebrew/brew. For CI, homebrew/ubuntu22.04:master is recommended." > .docker-deprecate - docker build -t brew-deprecated --build-arg=version=16.04 \ - --label org.opencontainers.image.created="$(date --rfc-3339=seconds --utc)" \ - --label org.opencontainers.image.url="https://brew.sh" \ - --label org.opencontainers.image.documentation="https://docs.brew.sh" \ - --label org.opencontainers.image.source="https://github.com/${GITHUB_REPOSITORY}" \ - --label org.opencontainers.image.revision="${GITHUB_SHA}" \ - --label org.opencontainers.image.vendor="${GITHUB_REPOSITORY_OWNER}" \ - --label org.opencontainers.image.licenses="BSD-2-Clause" \ - --label org.opencontainers.image.support.end-of-support="2022-09-07T00:00:00Z" \ - . - - - name: Deploy the deprecated 16.04 Docker image to GitHub Packages and Docker Hub - if: github.ref == 'refs/heads/master' - run: | - docker tag brew-deprecated "ghcr.io/homebrew/ubuntu16.04:master" - docker push "ghcr.io/homebrew/ubuntu16.04:master" - docker tag brew-deprecated "homebrew/ubuntu16.04:master" - docker push "homebrew/ubuntu16.04:master" - update-test: name: ${{ matrix.name }} runs-on: ${{ matrix.runs-on }} diff --git a/Dockerfile b/Dockerfile index 5d79c46924..5f64a7014b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -25,6 +25,7 @@ RUN apt-get update \ g++ \ gawk \ git \ + gpg \ less \ libz-dev \ locales \ @@ -37,7 +38,6 @@ RUN apt-get update \ uuid-runtime \ tzdata \ jq \ - && if [ "$(. /etc/lsb-release; echo "${DISTRIB_RELEASE}" | cut -d. -f1)" -ge 18 ]; then apt-get install -y --no-install-recommends gpg; fi \ && if [ "$(. /etc/lsb-release; echo "${DISTRIB_RELEASE}" | cut -d. -f1)" -ge 22 ]; then apt-get install -y --no-install-recommends gh skopeo; fi \ && apt-get remove --purge -y software-properties-common \ && apt-get autoremove --purge -y \ diff --git a/docs/Linux-CI.md b/docs/Linux-CI.md index 8ef5c93688..502df5700c 100644 --- a/docs/Linux-CI.md +++ b/docs/Linux-CI.md @@ -1,6 +1,6 @@ # Linux CI in `homebrew/core` -We currently use Ubuntu 16.04 for bottling in `homebrew/core`. +We currently use Ubuntu 22.04 for bottling in `homebrew/core`. ## Ubuntu vs. other Linux distributions @@ -12,7 +12,8 @@ Our bottles are compatible with other distributions like Debian/CentOS, even whe ## Past and next versions -We are currently moving our CI to Ubuntu 22.04. This work will probably be done before end of 2022. +We have moved our CI to Ubuntu 22.04 + Moving from Ubuntu 16.04 to Ubuntu 22.04 (and thus skipping version 18.04 and 20.04) took longer than expected. We plan to proceed with regular updates from 2022 onwards. We aim to use the latest Ubuntu LTS version for our CI.