From 634c667ccd64d03f7af45c44d645a3e49ab50604 Mon Sep 17 00:00:00 2001 From: Janis Horsts Date: Sun, 22 Jun 2025 11:15:46 +0100 Subject: [PATCH 01/14] chore: fix CI workflow (#1) --- .arg | 3 ++- .github/CODEOWNERS | 4 ++-- .github/workflows/ci.yml | 41 ++++++++++++++++++++++-------------- README.md | 6 +++--- common/Earthfile | 45 +++++++++++++++++++++++++--------------- 5 files changed, 61 insertions(+), 38 deletions(-) diff --git a/.arg b/.arg index 455a198..a9fbc5e 100644 --- a/.arg +++ b/.arg @@ -1,3 +1,4 @@ -DOCKERHUB_USER=earthly +CR_HOST=ghcr.io +CR_ORG=earthbuild IMAGE_NAME=dind EARTHLY_REPO_VERSION=0b28ef80785fd88df1ec7e674475b02e046d5b36 diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index e2d3d45..231659a 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -1,2 +1,2 @@ -# PRs require approval from the earthly core team -* @earthly/core +# PRs require approval from the EarthBuild admin team +* @EarthBuild/fork-admins diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2363f68..63d9827 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,35 +5,46 @@ on: # push: # branches: [ "main" ] pull_request: - branches: [ "main" ] + branches: ["main"] concurrency: group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} cancel-in-progress: true - + jobs: test: name: test runs-on: ubuntu-latest + permissions: + contents: read + packages: write env: FORCE_COLOR: 1 EARTHLY_CONVERSION_PARALLELISM: "5" - EARTHLY_TOKEN: "${{ secrets.EARTHLY_TOKEN }}" - EARTHLY_INSTALL_ID: "earthly-dind-githubactions" + EARTHLY_INSTALL_ID: "earthbuild-dind-githubactions" steps: - - uses: earthly/actions/setup-earthly@v1 + # The dind (common+alpine-kind-test and common+ubuntu-kind-test) detects + # the host's IPv6 capability and then requires IPv6 NAT to create networks + # for kind. So we load it here. + # Ref: https://github.com/moby/moby/pull/47062 + - name: Load kernel module IPv6 NAT + run: sudo modprobe ip6table_nat + - name: Set up Docker Hub mirrors + run: | + sudo mkdir -p /etc/docker + echo '{"registry-mirrors": ["https://mirror.gcr.io", "https://public.ecr.aws"]}' | sudo tee /etc/docker/daemon.json + sudo systemctl restart docker + - name: Set up QEMU + run: | + sudo apt-get update + sudo apt-get install -y qemu-user-static binfmt-support + sudo update-binfmts --display + - uses: earthbuild/actions-setup@main with: version: v0.8.15 - uses: actions/checkout@v4 - - name: Docker login (non fork only) - run: |- - docker login --username "${{ secrets.DOCKERHUB_USERNAME }}" --password "${{ secrets.DOCKERHUB_TOKEN }}" - docker login registry-1.docker.io.mirror.corp.earthly.dev --username "${{ secrets.DOCKERHUB_MIRROR_USERNAME }}" --password "${{ secrets.DOCKERHUB_MIRROR_PASSWORD }}" - if: github.event.pull_request.head.repo.full_name == github.repository - - name: Configure Earthly to use mirror (non fork only) - run: |- - earthly config global.buildkit_additional_config "'[registry.\"docker.io\"] - mirrors = [\"registry-1.docker.io.mirror.corp.earthly.dev\"]'" + - name: Log in to GitHub Container Registry (non fork only) + run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.actor }} --password-stdin if: github.event.pull_request.head.repo.full_name == github.repository - name: Run tests - run: earthly --ci -P --push --org earthly-technologies --satellite dind +test + run: earthly --ci -P --push +test diff --git a/README.md b/README.md index 11c67ab..dba2302 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ For information on how to use these images, please refer to [docker in earthly]( ## Supported Distributions -There are currently 3 supported dind distributions available: +There are currently 4 supported dind distributions available: - `alpine` - `ubuntu:20.04` - `ubuntu:23.04` @@ -30,7 +30,7 @@ dependencies that will trigger new versions of the dind images such as the docke ```bash . -├── Earthfile // Targets that apply to all images (e.g. +test) +├── Earthfile // Targets that apply to all images (e.g. +test) ├── common │ └── Earthfile // A library of common helper targets └── os // Each directory contains an Earthfile with targets to maintain the specific os (e.g. +test, +build) @@ -65,7 +65,7 @@ earthly --push -P +test #### Community members -Community members do not have permissions to push a built image and run the tests against it. However, they can easily set a different dockerhub repository by changing the `DOCKERHUB_USER` ARG value in [.arg](.arg) to a private repository or by passing the arg in the earthly command, e.g. `earthly --push -P +test --DOCKERHUB_USER=`. +Community members do not have permissions to push a built image and run the tests against it. However, they can easily set a different container registry repository by changing the `CR_HOST` (default: ghcr.io) and `CR_ORG` ARG values in [.arg](.arg) to a private container registry repository or by passing the args in the earthly command, e.g. `earthly --push -P +test --CR_HOST= --CR_ORG=`. ## Deployment diff --git a/common/Earthfile b/common/Earthfile index 9a22e2e..1dc50df 100644 --- a/common/Earthfile +++ b/common/Earthfile @@ -6,14 +6,14 @@ FROM alpine # EARTHLY_REPO_VERSION specifies a branch and/or commit of earthly/earthly (it defaults to the earthly cli version if left empty) ARG EARTHLY_REPO_VERSION -IMPORT github.com/earthly/earthly/buildkitd:$EARTHLY_REPO_VERSION AS earthly -IMPORT github.com/earthly/earthly/tests/with-docker:$EARTHLY_REPO_VERSION AS with-docker -IMPORT github.com/earthly/earthly/tests/with-docker-compose:$EARTHLY_REPO_VERSION AS with-docker-compose -IMPORT github.com/earthly/earthly/tests/with-docker-kind:$EARTHLY_REPO_VERSION AS with-docker-kind -IMPORT github.com/earthly/earthly/tests/dind-auto-install:$EARTHLY_REPO_VERSION AS dind-auto-install +IMPORT github.com/EarthBuild/earthbuild/buildkitd:$EARTHLY_REPO_VERSION AS earthly +IMPORT github.com/EarthBuild/earthbuild/tests/with-docker:$EARTHLY_REPO_VERSION AS with-docker +IMPORT github.com/EarthBuild/earthbuild/tests/with-docker-compose:$EARTHLY_REPO_VERSION AS with-docker-compose +IMPORT github.com/EarthBuild/earthbuild/tests/with-docker-kind:$EARTHLY_REPO_VERSION AS with-docker-kind +IMPORT github.com/EarthBuild/earthbuild/tests/dind-auto-install:$EARTHLY_REPO_VERSION AS dind-auto-install -# DOCKERHUB_USER is the organization name in docker hub (default: earthly) -ARG --global DOCKERHUB_USER +# CR_ORG is the organization name in a container registry (default: earthbuild) +ARG --global CR_ORG # IMAGE_NAME is the image repository in docker hub (default: dind) ARG --global IMAGE_NAME @@ -26,14 +26,22 @@ build: # DOCKER_VERSION is the version of docker to use, e.g. 20.10.14 ARG --required DOCKER_VERSION FROM $OS_IMAGE:$OS_VERSION + # Ubuntu 23.04 has reached EOL + IF [ "$OS_VERSION" = "23.04" ] + RUN sed -i \ + -e 's/archive.ubuntu.com\/ubuntu/old-releases.ubuntu.com\/ubuntu/g' \ + -e 's/ports.ubuntu.com\/ubuntu-ports/old-releases.ubuntu.com\/ubuntu/g' \ + -e 's/security.ubuntu.com\/ubuntu/old-releases.ubuntu.com\/ubuntu/g' \ + /etc/apt/sources.list + END COPY earthly+export-docker-script/docker-auto-install.sh /usr/local/bin/docker-auto-install.sh RUN docker-auto-install.sh LET DOCKER_VERSION_TAG=$DOCKER_VERSION IF [ "$OS_IMAGE" = "alpine" ] RUN apk add iptables-legacy # required for older kernels END - # DOCKERHUB_USER is the organization name in docker hub (default: earthly) - ARG DOCKERHUB_USER + # CR_ORG is the organization name in container registry (default: earthbuild) + ARG CR_ORG # IMAGE_NAME is the image repository in docker hub (default: dind) ARG IMAGE_NAME COPY --dir --pass-args +get-image-info/image-info . @@ -41,7 +49,8 @@ build: LET image_tag=$(cat image-info/tag) RUN rm -rf image-info ENV OTEL_TRACES_EXPORTER=none # disabled for speed improvement; see https://github.com/earthly/earthly/issues/4066 - SAVE IMAGE --push $image_name:$image_tag + ARG --required CR_HOST + SAVE IMAGE --push $CR_HOST/$image_name:$image_tag # get-image-info generates the image name and tag as a saved artifact so it can be used by multiple targets get-image-info: @@ -59,11 +68,12 @@ get-image-info: RUN if echo $DOCKER_VERSION_TAG | grep "[^0-9.-]"; then echo "DOCKER_VERSION_TAG looks bad; got $DOCKER_VERSION_TAG" && exit 1; fi END LET TAG=$OS_IMAGE-$OS_VERSION-docker-$DOCKER_VERSION_TAG - # DOCKERHUB_USER is the organization name in docker hub (default: earthly) - ARG --required DOCKERHUB_USER + # CR_ORG is the organization name in container registry (default: earthbuild) + ARG --required CR_ORG # IMAGE_NAME is the image repository in docker hub (default: dind) ARG --required IMAGE_NAME - LET image_full_name=$DOCKERHUB_USER/$IMAGE_NAME + # image_full_name excludes container registry host + LET image_full_name=$CR_ORG/$IMAGE_NAME ARG SUFFIX IF [ -n "$SUFFIX" ] SET TAG="$TAG-$SUFFIX" @@ -75,7 +85,7 @@ get-image-info: # test runs tests against the specified image (DIND_IMAGE) or otherwise uses the image specified in earthly/earthly repo test: - # DIND_IMAGE is the full docker image name & tag to run the tests against. The image must exist in the remote docker registry + # DIND_IMAGE is the full container image name & tag to run the tests against. The image must exist in the remote container registry ARG DIND_IMAGE BUILD --pass-args with-docker+all --DIND_IMAGE=$DIND_IMAGE BUILD --pass-args dind-auto-install+test --BASE_IMAGE=$DIND_IMAGE @@ -95,11 +105,12 @@ build-and-test: COPY --dir --pass-args +get-image-info/image-info . LET image_name=$(cat image-info/name) LET image_tag=$(cat image-info/tag) + ARG --required CR_HOST WAIT # EARTHLY_PUSH is a builtin arg that helps determine if the tests should run ARG EARTHLY_PUSH IF [ "$EARTHLY_PUSH" = "true" ] - BUILD --pass-args ../os/$DIR_PATH+test --DIND_IMAGE=$image_name:$image_tag + BUILD --pass-args ../os/$DIR_PATH+test --DIND_IMAGE=$CR_HOST/$image_name:$image_tag END END @@ -114,12 +125,12 @@ push-new-tag: exit 1 END END - FROM $DOCKERHUB_USER/$IMAGE_NAME:$TAG_WITH_DATE + FROM $CR_ORG/$IMAGE_NAME:$TAG_WITH_DATE LET new_tag="$(echo ${TAG_WITH_DATE%-*})" IF [ "$new_tag" = "$TAG_WITH_DATE" ] RUN --no-cache echo "failed to remove date from tag $TAG_WITH_DATE" && exit 1 END - SAVE IMAGE --push $DOCKERHUB_USER/$IMAGE_NAME:$new_tag + SAVE IMAGE --push $CR_ORG/$IMAGE_NAME:$new_tag # push-new-tag-multi-platform builds push-new-tag using both amd64 & arm64 platforms. push-new-tag-multi-platform: From df684fa48e3f1f3f69ba599cbc0db62be1d0776d Mon Sep 17 00:00:00 2001 From: Janis Horsts Date: Wed, 25 Jun 2025 22:01:11 +0100 Subject: [PATCH 02/14] chore: fix Release workflow (#2) --- .github/workflows/ci.yml | 2 +- .github/workflows/release.yml | 39 ++++++++++++++++++++++++----------- README.md | 18 ++++++++-------- common/Earthfile | 5 +++-- 4 files changed, 40 insertions(+), 24 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 63d9827..0be996c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,6 +23,7 @@ jobs: EARTHLY_CONVERSION_PARALLELISM: "5" EARTHLY_INSTALL_ID: "earthbuild-dind-githubactions" steps: + - uses: actions/checkout@v4 # The dind (common+alpine-kind-test and common+ubuntu-kind-test) detects # the host's IPv6 capability and then requires IPv6 NAT to create networks # for kind. So we load it here. @@ -42,7 +43,6 @@ jobs: - uses: earthbuild/actions-setup@main with: version: v0.8.15 - - uses: actions/checkout@v4 - name: Log in to GitHub Container Registry (non fork only) run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.actor }} --password-stdin if: github.event.pull_request.head.repo.full_name == github.repository diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 63bdd51..736e4c6 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -9,25 +9,40 @@ jobs: name: release after merging ${{ github.head_ref }} if: github.event.pull_request.merged == true && startsWith(github.head_ref, 'renovate/') && endsWith(github.head_ref, '-dind-image') runs-on: ubuntu-latest + permissions: + contents: read + packages: write env: FORCE_COLOR: 1 EARTHLY_CONVERSION_PARALLELISM: "5" - EARTHLY_TOKEN: "${{ secrets.EARTHLY_TOKEN }}" - EARTHLY_INSTALL_ID: "earthly-dind-githubactions" + EARTHLY_INSTALL_ID: "earthbuild-dind-githubactions" steps: - - uses: earthly/actions/setup-earthly@v1 + - uses: actions/checkout@v4 + # The dind (common+alpine-kind-test and common+ubuntu-kind-test) detects + # the host's IPv6 capability and then requires IPv6 NAT to create networks + # for kind. So we load it here. + # Ref: https://github.com/moby/moby/pull/47062 + - name: Load kernel module IPv6 NAT + run: sudo modprobe ip6table_nat + - name: Set up Docker Hub mirrors + run: | + sudo mkdir -p /etc/docker + echo '{"registry-mirrors": ["https://mirror.gcr.io", "https://public.ecr.aws"]}' | sudo tee /etc/docker/daemon.json + sudo systemctl restart docker + - name: Set up QEMU + run: | + sudo apt-get update + sudo apt-get install -y qemu-user-static binfmt-support + sudo update-binfmts --display + - uses: earthbuild/actions-setup@main with: version: v0.8.15 - - uses: actions/checkout@v4 - - name: Docker login (non fork only) + - name: Log in to container registries (non fork only) run: |- docker login --username "${{ secrets.DOCKERHUB_USERNAME }}" --password "${{ secrets.DOCKERHUB_TOKEN }}" - docker login registry-1.docker.io.mirror.corp.earthly.dev --username "${{ secrets.DOCKERHUB_MIRROR_USERNAME }}" --password "${{ secrets.DOCKERHUB_MIRROR_PASSWORD }}" - if: github.event.pull_request.head.repo.full_name == github.repository - - name: Configure Earthly to use mirror (non fork only) - run: |- - earthly config global.buildkit_additional_config "'[registry.\"docker.io\"] - mirrors = [\"registry-1.docker.io.mirror.corp.earthly.dev\"]'" + docker login ghcr.io --username ${{ github.actor }} --password "${{ secrets.GITHUB_TOKEN }}" if: github.event.pull_request.head.repo.full_name == github.repository - name: Build & Push image - run: earthly --ci -P --push --org earthly-technologies --satellite dind +release --RENOVATE_BRANCH=${{github.head_ref}} + run: | + earthly --ci -P --push +release --RENOVATE_BRANCH=${{github.head_ref}} # default:ghcr.io + earthly --ci -P --push +release --RENOVATE_BRANCH=${{github.head_ref}} --CR_HOST=docker.io diff --git a/README.md b/README.md index dba2302..8062eae 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,10 @@ -# Earthly dind (Docker In Docker) Images -[![Release](https://github.com/earthly/dind/actions/workflows/release.yml/badge.svg)](https://github.com/earthly/dind/actions/workflows/release.yml) -![Docker Pulls](https://img.shields.io/docker/pulls/earthly/dind) +# EarthBuild dind (Docker In Docker) Images +[![Release](https://github.com/earthbuild/dind/actions/workflows/release.yml/badge.svg)](https://github.com/earthbuild/dind/actions/workflows/release.yml) +![Docker Pulls](https://img.shields.io/docker/pulls/earthbuild/dind) -Earthly's official [earthly/dind](https://hub.docker.com/repository/docker/earthly/dind/general) docker images. -For information on how to use these images, please refer to [docker in earthly](https://docs.earthly.dev/docs/guides/docker-in-earthly). +EarthBuilds's official [ghcr.io/earthbuild/dind](https://ghcr.io/earthbuild/dind) and [earthbuild/dind](https://hub.docker.com/r/earthlbuild/dind) container images. +For information on how to use these images, please refer to [docker in EarthBuild](https://docs.earthly.dev/docs/guides/docker-in-earthly). ## Supported Distributions @@ -19,7 +19,7 @@ Other distributions and/or base images can be used with our [dind+INSTALL](https ## How Images are Built In this repository, we maintain the OS & Docker versions that warrants releasing a new version of the image. -However, the installations of docker and other dependencies are done via an installation script that is currently maintained in [earthly/earthly](https://github.com/earthly/earthly). +However, the installations of docker and other dependencies are done via an installation script that is currently maintained in [earthbuild/earthbuild](https://github.com/earthbuild/earthbuild). ### Dependencies @@ -46,7 +46,7 @@ dependencies that will trigger new versions of the dind images such as the docke ## Testing -Images are tested by running remote test targets that are maintained in [earthly/earthly](https://github.com/earthly/earthly/tree/main/tests/with-docker). This is because these tests also help test [WITH DOCKER](https://docs.earthly.dev/docs/earthfile#with-docker) command in earthly cli. +Images are tested by running remote test targets that are maintained in [earthbuild/earthbuild](https://github.com/earthbuild/earthbuild/tree/main/tests/with-docker). This is because these tests also help test [WITH DOCKER](https://docs.earthly.dev/docs/earthfile#with-docker) command in earthly cli. Temporary images are built, pushed, and pulled as part of the test cycle. @@ -69,11 +69,11 @@ Community members do not have permissions to push a built image and run the test ## Deployment -When the relevant dependencies are updates by Renovate, new images/tags will be pushed automatically to the docker registry. +When the relevant dependencies are updated by Renovate, new images/tags will be pushed automatically to the container registries - [ghcr.io/earthbuild/dind](https://ghcr.io/earthbuild/dind) and [earthbuild/dind](https://hub.docker.com/r/earthlbuild/dind). ## Contributing -* Please report bugs as [GitHub issues](https://github.com/earthly/dind/issues). +* Please report bugs as [GitHub issues](https://github.com/earthbuild/dind/issues). * Join us on [Slack](https://earthly.dev/slack)! * Questions via GitHub issues are welcome! * PRs welcome! But please give a heads-up in a GitHub issue before starting work. If there is no GitHub issue for what you want to do, please create one. diff --git a/common/Earthfile b/common/Earthfile index 1dc50df..8b415d7 100644 --- a/common/Earthfile +++ b/common/Earthfile @@ -125,12 +125,13 @@ push-new-tag: exit 1 END END - FROM $CR_ORG/$IMAGE_NAME:$TAG_WITH_DATE + ARG --required CR_HOST + FROM $CR_HOST/$CR_ORG/$IMAGE_NAME:$TAG_WITH_DATE LET new_tag="$(echo ${TAG_WITH_DATE%-*})" IF [ "$new_tag" = "$TAG_WITH_DATE" ] RUN --no-cache echo "failed to remove date from tag $TAG_WITH_DATE" && exit 1 END - SAVE IMAGE --push $CR_ORG/$IMAGE_NAME:$new_tag + SAVE IMAGE --push $CR_HOST/$CR_ORG/$IMAGE_NAME:$new_tag # push-new-tag-multi-platform builds push-new-tag using both amd64 & arm64 platforms. push-new-tag-multi-platform: From 4ec0d0be01d917050cda037ac7995768a9733e9a Mon Sep 17 00:00:00 2001 From: Janis Horsts Date: Wed, 2 Jul 2025 20:29:43 +0100 Subject: [PATCH 03/14] chore: fix renovate (#3) --- .github/renovate.json5 | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/.github/renovate.json5 b/.github/renovate.json5 index a10c498..bca5548 100644 --- a/.github/renovate.json5 +++ b/.github/renovate.json5 @@ -6,7 +6,8 @@ configMigration: true, prHourlyLimit: 1, schedule: [ // utc timezone - 'after 6am on monday', + // TODO(jhorsts): uncomment when workflows work as expected + // 'after 6am on monday', ], enabledManagers: [ 'dockerfile', @@ -20,15 +21,15 @@ }, customManagers: [ { - // Earthly Version in GH Actions + // Earthbuild Version in GH Actions customType: 'regex', fileMatch: [ - '.*?\\.yml', + '.*?\\.yml', ], matchStrings: [ - '- uses: earthly/actions/setup-earthly@.*?[\\s\\n]+.*?[\\s\\n]+with:[\\s\\n]*version: (?.*?)[\\s\\n/]+', + '- uses: earthbuild/actions-setup@.*?[\\s\\n]+.*?[\\s\\n]+with:[\\s\\n]*version: (?.*?)[\\s\\n/]+', ], - depNameTemplate: 'earthly/earthly', + depNameTemplate: 'earthbuild/earthbuild', datasourceTemplate: 'github-releases', }, { @@ -57,15 +58,15 @@ autoReplaceStringTemplate: '# renovate: datasource=repology depName=alpine_{{{newMajor}}}_{{{newMinor}}}', }, { - // Updating the commit hash of earthly/earthly + // Updating the commit hash of earthbuild/earthbuild customType: 'regex', fileMatch: ['^\\.arg$'], matchStrings: [ 'EARTHLY_REPO_VERSION=(?.*?)($|\\s|\\n)', ], currentValueTemplate: 'main', - depNameTemplate: 'earthly/earthly', - packageNameTemplate: 'https://github.com/earthly/earthly', + depNameTemplate: 'earthbuild/earthbuild', + packageNameTemplate: 'https://github.com/earthbuild/earthbuild', datasourceTemplate: 'git-refs', }, { @@ -76,7 +77,7 @@ matchStrings: [ '\\*\\s+\\`(?.+?)\\`\\n', ], - depNameTemplate: 'earthly/dind', + depNameTemplate: 'earthbuild/dind', datasourceTemplate: 'docker', }, ], @@ -110,33 +111,33 @@ automerge: true, }, { - // rule to update earthly/dind:alpine-* images + // rule to update earthbuild/dind:alpine-* images groupName: 'docs-dind-images', - matchPackageNames: ['earthly/dind'], + matchPackageNames: ['earthbuild/dind'], matchCurrentVersion: "/^alpine-.*/", allowedVersions: "/^alpine-.*/", versioning: "regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-r(?\\d+)$", }, { - // rule to update earthly/dind:ubuntu:20.04-* images + // rule to update earthbuild/dind:ubuntu:20.04-* images groupName: 'docs-dind-images', - matchPackageNames: ['earthly/dind'], + matchPackageNames: ['earthbuild/dind'], matchCurrentVersion: "/^ubuntu-20\\.04-.*/", allowedVersions: "/^ubuntu-20\\.04-.*/", versioning: "regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-(?\\d+)$", }, { - // rule to update earthly/dind:ubuntu:23.04-* images + // rule to update earthbuild/dind:ubuntu:23.04-* images groupName: 'docs-dind-images', - matchPackageNames: ['earthly/dind'], + matchPackageNames: ['earthbuild/dind'], matchCurrentVersion: "/^ubuntu-23\\.04-.*/", allowedVersions: "/^ubuntu-23\\.04-.*/", versioning: "regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-(?\\d+)$", }, { - // rule to update earthly/dind:ubuntu:24.04-* images + // rule to update earthbuild/dind:ubuntu:24.04-* images groupName: 'docs-dind-images', - matchPackageNames: ['earthly/dind'], + matchPackageNames: ['earthbuild/dind'], matchCurrentVersion: "/^ubuntu-24\\.04-.*/", allowedVersions: "/^ubuntu-24\\.04-.*/", versioning: "regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-(?\\d+)$", From 8759b139833adcb6f2e71de62c59a7aba208a201 Mon Sep 17 00:00:00 2001 From: Janis Horsts Date: Thu, 3 Jul 2025 08:23:56 +0100 Subject: [PATCH 04/14] chore(renovate): enable forkProcessing (#4) --- .github/renovate.json5 | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/renovate.json5 b/.github/renovate.json5 index bca5548..7eafd6a 100644 --- a/.github/renovate.json5 +++ b/.github/renovate.json5 @@ -3,6 +3,7 @@ extends: [ "config:recommended" ], + forkProcessing: "enabled", configMigration: true, prHourlyLimit: 1, schedule: [ // utc timezone From fcc8111a0b37a424c82cdb8cfba4a48c1e3cf7e1 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 9 Jul 2025 18:21:41 +0000 Subject: [PATCH 05/14] chore(deps): update earthbuild/earthbuild digest to c10f2cf (#5) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- .arg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.arg b/.arg index a9fbc5e..355e4e9 100644 --- a/.arg +++ b/.arg @@ -1,4 +1,4 @@ CR_HOST=ghcr.io CR_ORG=earthbuild IMAGE_NAME=dind -EARTHLY_REPO_VERSION=0b28ef80785fd88df1ec7e674475b02e046d5b36 +EARTHLY_REPO_VERSION=c10f2cffa9a7020bc6f3c9fbb88fb89c66adf8bd From d87c1db768b99593dc80e01d3b70797040be356a Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 9 Jul 2025 19:59:03 +0100 Subject: [PATCH 06/14] chore(config): migrate config .github/renovate.json5 (#6) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Janis Horsts --- .github/renovate.json5 | 100 ++++++++++++++++++++--------------------- 1 file changed, 49 insertions(+), 51 deletions(-) diff --git a/.github/renovate.json5 b/.github/renovate.json5 index 7eafd6a..f1a8411 100644 --- a/.github/renovate.json5 +++ b/.github/renovate.json5 @@ -1,31 +1,27 @@ { - $schema: "https://docs.renovatebot.com/renovate-schema.json", + $schema: 'https://docs.renovatebot.com/renovate-schema.json', extends: [ - "config:recommended" + 'config:recommended', ], - forkProcessing: "enabled", + forkProcessing: 'enabled', configMigration: true, prHourlyLimit: 1, - schedule: [ // utc timezone - // TODO(jhorsts): uncomment when workflows work as expected - // 'after 6am on monday', - ], + schedule: [], enabledManagers: [ 'dockerfile', 'custom.regex', 'github-actions', ], dockerfile: { - fileMatch: [ - 'Earthfile', + managerFilePatterns: [ + '/Earthfile/', ], }, customManagers: [ { - // Earthbuild Version in GH Actions customType: 'regex', - fileMatch: [ - '.*?\\.yml', + managerFilePatterns: [ + '/.*?\\.yml/', ], matchStrings: [ '- uses: earthbuild/actions-setup@.*?[\\s\\n]+.*?[\\s\\n]+with:[\\s\\n]*version: (?.*?)[\\s\\n/]+', @@ -34,20 +30,18 @@ datasourceTemplate: 'github-releases', }, { - // ARG/LET in Earthfile that have a Renovate comment customType: 'regex', - fileMatch: [ - 'Earthfile', + managerFilePatterns: [ + '/Earthfile/', ], matchStrings: [ '\\s*#\\s*renovate:\\s*datasource=(?.*?)\\s+depName=(?.*?)[\\s\\n]+(versioning=(?.*?)\\s+)?(ARG|LET)\\s+.*?(_VERSION|_VER|version)=(?.*?)($|\\s|\\n)', ], }, { - // Updating the Repology alpine version customType: 'regex', - fileMatch: [ - 'Earthfile', + managerFilePatterns: [ + '/Earthfile/', ], matchStrings: [ '# renovate: datasource=repology depName=alpine_(?\\d+_\\d+)', @@ -59,9 +53,10 @@ autoReplaceStringTemplate: '# renovate: datasource=repology depName=alpine_{{{newMajor}}}_{{{newMinor}}}', }, { - // Updating the commit hash of earthbuild/earthbuild customType: 'regex', - fileMatch: ['^\\.arg$'], + managerFilePatterns: [ + '/^\\.arg$/', + ], matchStrings: [ 'EARTHLY_REPO_VERSION=(?.*?)($|\\s|\\n)', ], @@ -72,8 +67,8 @@ }, { customType: 'regex', - fileMatch: [ - 'docs/dockerhub.md$', + managerFilePatterns: [ + '/docs/dockerhub.md$/', ], matchStrings: [ '\\*\\s+\\`(?.+?)\\`\\n', @@ -86,14 +81,8 @@ 'renovate', ], packageRules: [ - // set the group name for alpine dind dependencies { groupName: "{{{ replace 'os\\/(.*?)$' '$1' packageFileDir}}}-dind-image", - matchPackagePatterns: [ - 'alpine', - 'alpine.*?/docker', - 'docker/docker', - ], matchManagers: [ 'custom.regex', ], @@ -105,46 +94,55 @@ matchFileNames: [ 'os/**/Earthfile', ], + matchPackageNames: [ + '/alpine/', + '/alpine.*?/docker/', + '/docker/docker/', + ], }, { - // let all package updates auto merge - matchPackagePatterns: [ '*' ], automerge: true, + matchPackageNames: [ + '*', + ], }, { - // rule to update earthbuild/dind:alpine-* images groupName: 'docs-dind-images', - matchPackageNames: ['earthbuild/dind'], - matchCurrentVersion: "/^alpine-.*/", - allowedVersions: "/^alpine-.*/", - versioning: "regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-r(?\\d+)$", + matchPackageNames: [ + 'earthbuild/dind', + ], + matchCurrentVersion: '/^alpine-.*/', + allowedVersions: '/^alpine-.*/', + versioning: 'regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-r(?\\d+)$', }, { - // rule to update earthbuild/dind:ubuntu:20.04-* images groupName: 'docs-dind-images', - matchPackageNames: ['earthbuild/dind'], - matchCurrentVersion: "/^ubuntu-20\\.04-.*/", - allowedVersions: "/^ubuntu-20\\.04-.*/", - versioning: "regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-(?\\d+)$", + matchPackageNames: [ + 'earthbuild/dind', + ], + matchCurrentVersion: '/^ubuntu-20\\.04-.*/', + allowedVersions: '/^ubuntu-20\\.04-.*/', + versioning: 'regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-(?\\d+)$', }, { - // rule to update earthbuild/dind:ubuntu:23.04-* images groupName: 'docs-dind-images', - matchPackageNames: ['earthbuild/dind'], - matchCurrentVersion: "/^ubuntu-23\\.04-.*/", - allowedVersions: "/^ubuntu-23\\.04-.*/", - versioning: "regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-(?\\d+)$", + matchPackageNames: [ + 'earthbuild/dind', + ], + matchCurrentVersion: '/^ubuntu-23\\.04-.*/', + allowedVersions: '/^ubuntu-23\\.04-.*/', + versioning: 'regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-(?\\d+)$', }, { - // rule to update earthbuild/dind:ubuntu:24.04-* images groupName: 'docs-dind-images', - matchPackageNames: ['earthbuild/dind'], - matchCurrentVersion: "/^ubuntu-24\\.04-.*/", - allowedVersions: "/^ubuntu-24\\.04-.*/", - versioning: "regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-(?\\d+)$", + matchPackageNames: [ + 'earthbuild/dind', + ], + matchCurrentVersion: '/^ubuntu-24\\.04-.*/', + allowedVersions: '/^ubuntu-24\\.04-.*/', + versioning: 'regex:^(?.*)-(?\\d+\\.\\d+)-docker-(?\\d+)\\.(?\\d+)\\.(?\\d+)-(?\\d+)$', }, { - // create PRs for multiple docker versions in case we're more than one major version behind matchPackageNames: [ 'docker/docker', ], From 8c671002a264ba73ff5e8fb84afc9ba8dbba71be Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 9 Jul 2025 22:23:08 +0000 Subject: [PATCH 07/14] chore(deps): update peter-evans/dockerhub-description action to v4.0.2 (#8) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- .github/workflows/update_readme.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/update_readme.yml b/.github/workflows/update_readme.yml index 7e9cd15..47e8989 100644 --- a/.github/workflows/update_readme.yml +++ b/.github/workflows/update_readme.yml @@ -17,7 +17,7 @@ jobs: with: token: ${{ secrets.GITHUB_TOKEN }} - name: Update DockerHub description for earthly/dind - uses: peter-evans/dockerhub-description@v4.0.0 + uses: peter-evans/dockerhub-description@v4.0.2 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_TOKEN }} From db8ef7e079402486f4106e6ee152565b8bc740ec Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 10 Jul 2025 00:08:43 +0100 Subject: [PATCH 08/14] chore(deps): update alpine docker tag to v3.22 (#9) * chore(deps): update alpine docker tag to v3.22 * chore: bump docker to 28.3.0 in alpine --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Janis Horsts --- os/alpine/Earthfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/os/alpine/Earthfile b/os/alpine/Earthfile index 4e28a73..4a9e0ee 100644 --- a/os/alpine/Earthfile +++ b/os/alpine/Earthfile @@ -9,9 +9,9 @@ IMPORT ../../common AS common ARG --global OS_IMAGE=alpine # renovate: datasource=docker depName=alpine -ARG --global OS_VERSION=3.20 -# renovate: datasource=repology depName=alpine_3_20/docker versioning=loose -ARG --global DOCKER_VERSION=26.1.5-r0 +ARG --global OS_VERSION=3.22 +# renovate: datasource=repology depName=alpine_3_22/docker versioning=loose +ARG --global DOCKER_VERSION=28.3.0-r0 # DIR_PATH is set to that common targets can call os specific targets. It should match the directory name this Earthfile is located in ARG --global DIR_PATH=$OS_IMAGE From 5a214b1c4cedbcf86c4f885aef76c58b82b3d155 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 10 Jul 2025 02:49:16 +0000 Subject: [PATCH 09/14] chore(deps): update dependency docker/docker to v27.5.1 (#10) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- os/ubuntu-20.04/Earthfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/os/ubuntu-20.04/Earthfile b/os/ubuntu-20.04/Earthfile index a6ec062..e0d7d6c 100644 --- a/os/ubuntu-20.04/Earthfile +++ b/os/ubuntu-20.04/Earthfile @@ -10,7 +10,7 @@ ARG --global OS_IMAGE=ubuntu ARG --global OS_VERSION=20.04 # renovate: datasource=github-releases depName=docker/docker -LET docker_package_version=27.2.1 +LET docker_package_version=27.5.1 ARG --global DOCKER_VERSION=5:$docker_package_version-1~ubuntu.$OS_VERSION~focal # DIR_PATH is set to that common targets can call os specific targets. It should match the directory name this Earthfile is located in From 27a58f1a20a3aaa846acff4219435da151a6b475 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 10 Jul 2025 06:18:22 +0000 Subject: [PATCH 10/14] chore(deps): update dependency docker/docker to v27.5.1 (#11) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- os/ubuntu-24.04/Earthfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/os/ubuntu-24.04/Earthfile b/os/ubuntu-24.04/Earthfile index fcfbcb0..14f484a 100644 --- a/os/ubuntu-24.04/Earthfile +++ b/os/ubuntu-24.04/Earthfile @@ -10,7 +10,7 @@ ARG --global OS_IMAGE=ubuntu ARG --global OS_VERSION=24.04 # renovate: datasource=github-releases depName=docker/docker -LET docker_package_version=27.3.1 +LET docker_package_version=27.5.1 ARG --global DOCKER_VERSION=5:$docker_package_version-1~ubuntu.$OS_VERSION~noble # DIR_PATH is set to that common targets can call os specific targets. It should match the directory name this Earthfile is located in From c19250eb74beba10463a96cae4e82b29a8e6b19d Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 10 Jul 2025 06:51:56 +0000 Subject: [PATCH 11/14] chore(deps): update docs-dind-images (#12) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- docs/dockerhub.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/dockerhub.md b/docs/dockerhub.md index 3532d0c..72956b8 100644 --- a/docs/dockerhub.md +++ b/docs/dockerhub.md @@ -11,8 +11,8 @@ This image supports 3 Linux distributions: * ubuntu:24.04 For which the current latest tags (respectively) are: -* `alpine-3.20-docker-26.1.5-r0` -* `ubuntu-20.04-docker-27.2.1-1` +* `alpine-3.22-docker-28.3.0-r0` +* `ubuntu-20.04-docker-27.5.1-1` * `ubuntu-23.04-docker-25.0.2-1` * `ubuntu-24.04-docker-27.3.1-1` From 7d8f530ec7bdac7ac3a64c12f9f0d0d4f73a38e3 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 10 Jul 2025 16:47:47 +0000 Subject: [PATCH 12/14] chore(deps): update earthbuild/dind docker tag to ubuntu-24.04-docker-27.5.1-1 (#14) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- docs/dockerhub.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/dockerhub.md b/docs/dockerhub.md index 72956b8..70680e9 100644 --- a/docs/dockerhub.md +++ b/docs/dockerhub.md @@ -14,7 +14,7 @@ For which the current latest tags (respectively) are: * `alpine-3.22-docker-28.3.0-r0` * `ubuntu-20.04-docker-27.5.1-1` * `ubuntu-23.04-docker-25.0.2-1` -* `ubuntu-24.04-docker-27.3.1-1` +* `ubuntu-24.04-docker-27.5.1-1` For other available tags, please check out https://hub.docker.com/r/earthly/dind/tags From cf4d34b32acff1fa0d760d91715add99efc70a21 Mon Sep 17 00:00:00 2001 From: Janis Horsts Date: Thu, 10 Jul 2025 19:08:07 +0100 Subject: [PATCH 13/14] chore(deps): lock docker/docker to v25.0.2 for ubuntu-23.04 --- .github/renovate.json5 | 9 +++++++++ os/ubuntu-23.04/Earthfile | 2 ++ 2 files changed, 11 insertions(+) diff --git a/.github/renovate.json5 b/.github/renovate.json5 index f1a8411..98fcca0 100644 --- a/.github/renovate.json5 +++ b/.github/renovate.json5 @@ -100,6 +100,15 @@ '/docker/docker/', ], }, + { + matchFileNames: [ + 'os/ubuntu-23.04/Earthfile', + ], + matchPackageNames: [ + 'docker/docker', + ], + allowedVersions: '25.0.2', + }, { automerge: true, matchPackageNames: [ diff --git a/os/ubuntu-23.04/Earthfile b/os/ubuntu-23.04/Earthfile index 0909ce0..157e3e1 100644 --- a/os/ubuntu-23.04/Earthfile +++ b/os/ubuntu-23.04/Earthfile @@ -9,6 +9,8 @@ IMPORT ../../common AS common ARG --global OS_IMAGE=ubuntu ARG --global OS_VERSION=23.04 + +# Docker v25.0.2 is the last version supported by the Docker apt repo. # renovate: datasource=github-releases depName=docker/docker LET docker_package_version=25.0.2 ARG --global DOCKER_VERSION=5:$docker_package_version-1~ubuntu.$OS_VERSION~lunar From 373badc65e6b9d705bd6685ca72d1713f383a7aa Mon Sep 17 00:00:00 2001 From: Janis Horsts Date: Thu, 10 Jul 2025 19:19:47 +0100 Subject: [PATCH 14/14] chore: remove comment --- os/ubuntu-23.04/Earthfile | 2 -- 1 file changed, 2 deletions(-) diff --git a/os/ubuntu-23.04/Earthfile b/os/ubuntu-23.04/Earthfile index 157e3e1..0909ce0 100644 --- a/os/ubuntu-23.04/Earthfile +++ b/os/ubuntu-23.04/Earthfile @@ -9,8 +9,6 @@ IMPORT ../../common AS common ARG --global OS_IMAGE=ubuntu ARG --global OS_VERSION=23.04 - -# Docker v25.0.2 is the last version supported by the Docker apt repo. # renovate: datasource=github-releases depName=docker/docker LET docker_package_version=25.0.2 ARG --global DOCKER_VERSION=5:$docker_package_version-1~ubuntu.$OS_VERSION~lunar