Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pushing cache to "registry" cache with multi-node builder only uploads cache from one node #1044

Open
potiuk opened this issue Apr 4, 2022 · 13 comments

Comments

@potiuk
Copy link

potiuk commented Apr 4, 2022

Originally reported at moby/buildkit#2758

It's been confirmed by @tonistiigi that this is a problem with buildx multi-node builder.

When you are building a multi-platform image with multiple builders (to avoid emulation) and use --cache-to type=registry, the resulting registry cache only contains cache for the platform that that was build last.

I tried to utilize buildkit to build Apache Airflow (https://github.com/apache/airflow) multi-platform images. I am using latest buildkit and latest docker:.

Hosts used for the multi-platform builds

I have two builder hosts:

  1. AMD builder (Linux Mint 20.3) with buildx plugin installed
    github.com/docker/buildx v0.7.1 0584689 - docker builder created there

  2. ARM Builder (Mac Pro M1 late 2021) with DockerDesktop 4.6.0 (with buildx pre-install installed) - with new Virtualization framework enabled.

Builder configuration

I configured my buildx builds to use both builders. I connected the MacOS builder to the Linux Host via forwarded docker socket and I am running all my multi-platform builds from the Linux Host.

This is the builders I see with docker buildx ls:

airflow_cache       docker-container                     
  airflow_cache0    unix:///var/run/docker.sock running  linux/amd64, linux/amd64/v2, linux/amd64/v3, linux/ppc64le, linux/s390x, linux/386, linux/mips64le, linux/mips64
  airflow_cache1    tcp://127.0.0.1:2375        running  linux/arm64, linux/amd64, linux/amd64/v2, linux/riscv64, linux/ppc64le, linux/s390x, linux/386, linux/mips64le, linux/mips64, linux/arm/v7, linux/arm/v6

Build command

I want to build a multi-platform image for both ARM and AMD and I want to do it in a single buildx command. Additionally I want to store cache for both platfiorms in the same image but with :cache tag.

My image is multi-staging, so I want to push cache for all stages (hence mode=max)

The (simpliified) command to run the build is:

docker buildx build --progress=default --pull --platform linux/amd64,linux/arm64 \
    --cache-from=ghcr.io/potiuk/airflow/main/ci/python3.7:cache \
    --cache to=type=registry,ref=ghcr.io/potiuk/airflow/main/ci/python3.7:cache,mode=max  \
    --push 
    -t ghcr.io/potiuk/airflow/main/ci/python3.7:latest --target main . -f Dockerfile.ci

While the ghcr.io/potiuk/airflow/main/ci/python3.7:latest image is perfectly fine (nice, multiplatform image), the ghcr.io/potiuk/airflow/main/ci/python3.7:cache image only contains cache by the "LAST" build image - i.e if the AMD image was faster to build and push cache, the cache from the ARM builder pushed later seems to override the AMD cache stored there.
I could not find any way to somehow merge those two caches (especially that I cannot specifiy two different cache destination for each of the platforms). This renders the --cache-to,type=registrry essentially useless for multiplatform builds.

I reverted to "inline" mode and it seems to work, but I would really love to keep the latest cache in a separate tag of the image.

@tonistiigi tonistiigi changed the title Pushing cache to "registry" cache with multiplatform builds does not produce multi-platform cache Pushing cache to "registry" cache with multi-node builder only uploads cache from one node Apr 6, 2022
@Nick-0314
Copy link

The cache of arm64 overwrites the cache of amD64, causing only one of the two platforms to be available. Using inline mode was a bit expensive for us to manage local storage, there were frequent disk space runs out, and the cache would disappear after the BuildKit container was restarted

@Nick-0314
Copy link

Nick-0314 commented May 7, 2022

@tonistiigi Can this problem be circumvented by adding the default schema suffix to cache-to-Registry? For example: "repo/ubuntu:cache-linux-arm64". Is this easy to develop? It is currently possible to define multiple cache-from, but once cache-to can be suffixed, I can cache-from multiple schemas

@potiuk
Copy link
Author

potiuk commented May 7, 2022

This is what I am planning to do - but then such multiplatform image cannot be prepared with single buildx command because you can specify only one --cache-to when you run single multi-platform build even with remote builders

Which renders buildx feature of preparing multi-platform image with remote builders in a single command pretty useless.

@potiuk
Copy link
Author

potiuk commented May 7, 2022

What I actually plan to do is do it in two steps (until it is fixed):

  1. Build a single multiplatform image and push it without cache
  2. Run separate two steps to AGAIN build and push (only cache) in two separate commands for two platforms separately

This is quite an overhead though the build cacje in builders will be reused so the overhead for running 3 commands instead of one should be bearable.

@Rongronggg9
Copy link

Rongronggg9 commented May 7, 2022

@potiuk There is another workaround that does not require building twice.

Node *: build Docker image on its own and push it to a standalone repo with cache.
Main node: concat these images together

docker manifest create USERNAME/REPOSITORY:TAG --amend USERNAME/REPOSITORY-NODE1:TAG --amend USERNAME/REPOSITORY-NODE2:TAG --amend USERNAME/REPOSITORY-NODE*:TAG
docker manifest push USERNAME/REPOSITORY:TAG

Refer to https://github.com/knatnetwork/github-runner/blob/399a888e5c9de2a38854a07570df661d59749284/.github/workflows/build.yml#L116 if you need an actual use case.

I consider it is possible to use only one repo by just using a standalone image tag and cache tag for each node.

I consider docker manifest may also be able to operate registry-cache tags instead of just image tags, so probably there are other workarounds. If you do a try, could you please comment and let me know?

@potiuk
Copy link
Author

potiuk commented May 8, 2022

Yeah. That's what I wanted to avoid to manually manipulate manifests. I prefer to rely on buildx behaviour.

This way I do not have to rely or get the "Nodes" and can nicely use multi-node builder just knowing it's name (and then pushing cache can be done from any node).

Also I think it has some nice properties to separate the caches out in different tag. We have our own "development environment" called breeze which hides the complexity of where (and when) the cache is used from and it makes it easy to decide which cache to use based on platform. And it's makaes it super easy to track and diagnose user issues as they can copy&paste the verbose command they used and it's a bit easier to track the history of that particular cache. So I will stick to that.

The overhead is very little actually, because in both steps I use the same builders (ARM and AMD hardware based) and the first step just builds a single multplatform image with --push , where the two subsequent steps just run single platform cache but they are reusing the local cache already built in the first step.

potiuk added a commit to potiuk/airflow that referenced this issue May 8, 2022
This is another attempt to improve caching performance for
multi-platform images as the previous ones were undermined by a
bug in buildx multiplatform cache-to implementattion that caused
the image cache to be overwritten between platforms,
when multiple images were build.

The bug is created for the buildx behaviour at
docker/buildx#1044 and until it is fixed
we have to prpare separate caches for each platform and push them
to separate tags.

That adds a bit overhead on the building step, but for now it is
the simplest way we can workaround the bug if we do not want to
manually manipulate manifests and images.
@jedevc
Copy link
Collaborator

jedevc commented Sep 21, 2022

Currently, buildx has support for merging manifest outputs from the builder results. I think it should be possible to implement similar support for merging cache manifests, it should be very similar to the existing logic.

However, we don't have support for push-by-digest to just push content without a tag for the registry exporter, which would need to be a separate fix first on buildkit.

leahecole pushed a commit to GoogleCloudPlatform/composer-airflow that referenced this issue Oct 4, 2022
This is another attempt to improve caching performance for
multi-platform images as the previous ones were undermined by a
bug in buildx multiplatform cache-to implementattion that caused
the image cache to be overwritten between platforms,
when multiple images were build.

The bug is created for the buildx behaviour at
docker/buildx#1044 and until it is fixed
we have to prpare separate caches for each platform and push them
to separate tags.

That adds a bit overhead on the building step, but for now it is
the simplest way we can workaround the bug if we do not want to
manually manipulate manifests and images.

(cherry picked from commit 9a6baab5a271b28b6b3cbf96ffa151ac7dc79013)

GitOrigin-RevId: 9809ad75b6528ed3b8f307cb8dc15aafefc93169
leahecole pushed a commit to GoogleCloudPlatform/composer-airflow that referenced this issue Dec 7, 2022
This is another attempt to improve caching performance for
multi-platform images as the previous ones were undermined by a
bug in buildx multiplatform cache-to implementattion that caused
the image cache to be overwritten between platforms,
when multiple images were build.

The bug is created for the buildx behaviour at
docker/buildx#1044 and until it is fixed
we have to prpare separate caches for each platform and push them
to separate tags.

That adds a bit overhead on the building step, but for now it is
the simplest way we can workaround the bug if we do not want to
manually manipulate manifests and images.

(cherry picked from commit 9a6baab5a271b28b6b3cbf96ffa151ac7dc79013)

GitOrigin-RevId: 9809ad75b6528ed3b8f307cb8dc15aafefc93169
@lorenzogrv
Copy link

lorenzogrv commented Jan 11, 2023

Same problem here. We build at CI using a dual remote builders strategy, partial code to exemplify:

  - docker buildx create --name buildx --driver docker-container --use --platform linux/amd64 --bootstrap ssh://$AMD64_HOST
  - docker buildx create --name buildx --append --platform linux/arm64 --bootstrap ssh://$ARM64_HOST
  - docker buildx build
      --push
      --platform linux/amd64,linux/arm64
     --cache-from=registry.example.null/image-name:buildcache
     --cache-to=type=registry,mode=max,ref=registry.example.null/image-name:buildcache
     --tag registry.example.null/image-name:example-tag
    # ...

The :buildcache image will only store the cache for the last completed build. As the cache isn't for both platforms, it "rotates" between each one each time the CI builds

I will attempt to adapt the @Rongronggg9 workaround (thanks for sharing <3) and report here for reference

leahecole pushed a commit to GoogleCloudPlatform/composer-airflow that referenced this issue Jan 27, 2023
This is another attempt to improve caching performance for
multi-platform images as the previous ones were undermined by a
bug in buildx multiplatform cache-to implementattion that caused
the image cache to be overwritten between platforms,
when multiple images were build.

The bug is created for the buildx behaviour at
docker/buildx#1044 and until it is fixed
we have to prpare separate caches for each platform and push them
to separate tags.

That adds a bit overhead on the building step, but for now it is
the simplest way we can workaround the bug if we do not want to
manually manipulate manifests and images.

GitOrigin-RevId: 9a6baab5a271b28b6b3cbf96ffa151ac7dc79013
@lorenzogrv
Copy link

lorenzogrv commented Feb 9, 2023

We noticed the problem no longer persist after bumping our CI jobs to use docker:20.10.23 with docker:20.10.23-dind service.

Both cache exported and imported seem correct, build times reduced to a range similar to local usage with local cache.

@digglife
Copy link

Hmm, bumped into this today. Seems I have to do the manifest manually.

@andrey-bondar
Copy link

Hey! Any new about this issue?

felipecrs added a commit to felipecrs/docker-images that referenced this issue Mar 20, 2024
felipecrs added a commit to felipecrs/docker-images that referenced this issue Mar 20, 2024
felipecrs added a commit to felipecrs/docker-images that referenced this issue Mar 20, 2024
felipecrs added a commit to felipecrs/docker-images that referenced this issue Mar 20, 2024
felipecrs added a commit to felipecrs/docker-images that referenced this issue Mar 20, 2024
felipecrs added a commit to felipecrs/docker-images that referenced this issue Mar 20, 2024
maayanyosef added a commit to explorium-ai/jenkins-agent-dind that referenced this issue Jul 28, 2024
* Downgrade docker compose from 2.19.1 to 2.18.1

Because of docker/compose#10751

* Revert "Downgrade docker compose from 2.19.1 to 2.18.1"

Because docker compose 2.20.2 solves the issue.

This reverts commit d0e25e5.

* Downgrade JDK from 11.0.20 to to 11.0.19 (felipecrs#76)

* Align remoting version with jenkins/docker-agent

So we don't try to use non-tested versions of the remoting library.

Also adds some dependencies from jenkins/docker-agent that were missing
in this image.

* Bump dind hack to latest version

* Clean not needed data like man pages

* Switch skopeo installation to skopeo-bin

* Upgrade fixuid from 0.5.1 to 0.6.0

* Add retry (felipecrs#80)

* Fix some hadolint issues

* Bump actions/checkout from 3 to 4 (felipecrs#81)

Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](actions/checkout@v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump docker/metadata-action from 4 to 5 (felipecrs#85)

Bumps [docker/metadata-action](https://github.com/docker/metadata-action) from 4 to 5.
- [Release notes](https://github.com/docker/metadata-action/releases)
- [Upgrade guide](https://github.com/docker/metadata-action/blob/master/UPGRADE.md)
- [Commits](docker/metadata-action@v4...v5)

---
updated-dependencies:
- dependency-name: docker/metadata-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump docker/build-push-action from 4 to 5 (felipecrs#84)

Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 4 to 5.
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](docker/build-push-action@v4...v5)

---
updated-dependencies:
- dependency-name: docker/build-push-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump docker/login-action from 2 to 3 (felipecrs#83)

Bumps [docker/login-action](https://github.com/docker/login-action) from 2 to 3.
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](docker/login-action@v2...v3)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump docker/setup-buildx-action from 2 to 3 (felipecrs#82)

Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 2 to 3.
- [Release notes](https://github.com/docker/setup-buildx-action/releases)
- [Commits](docker/setup-buildx-action@v2...v3)

---
updated-dependencies:
- dependency-name: docker/setup-buildx-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Honor default shell in /ssh-command/get.sh

* Upgrade s6-overlay from v2 to v3 (felipecrs#78)

* Revert "Downgrade JDK from 11.0.20 to to 11.0.19 (felipecrs#76)" (felipecrs#86)

This reverts commit 0c9a5a9.

* Revert "Upgrade s6-overlay from v2 to v3 (felipecrs#78)"

This reverts commit b074844, due to
just-containers/s6-overlay#558.

* Upgrade s6-overlay from v2 to v3 (felipecrs#78)""

This reverts commit 70ec592.

Refs felipecrs#78
Refs just-containers/s6-overlay#558 (comment)

* Downgrade and pin Node.js to v18 (felipecrs#90)

* Bump peter-evans/dockerhub-description from 3 to 4 (felipecrs#91)

Bumps [peter-evans/dockerhub-description](https://github.com/peter-evans/dockerhub-description) from 3 to 4.
- [Release notes](https://github.com/peter-evans/dockerhub-description/releases)
- [Commits](peter-evans/dockerhub-description@v3...v4)

---
updated-dependencies:
- dependency-name: peter-evans/dockerhub-description
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Update Ubuntu 20.04 to 22.04

* Fix minor README issues (felipecrs#93)

* Extract image preparation into a separate script and improve it (felipecrs#94)

Among other things, the new script no longer needs add-apt-repository,
changes the kubernetes debian repository to the new one.

As part of this improvement, we also change the base image from
buildpack to ubuntu, while still keeping the build-essential package
installed. This allows to trim the image size a little bit.

* Stop publishing to Docker Hub (felipecrs#95)

I prefer to concentrate on publishing to GitHub Container Registry, so
that I don't need to maintain two accounts and also because this way all
download counts are in one place.

As part of this change, I also removed the Docker image from Docker Hub,
so that when users try to download it again, it will fail and therefore
notice that the image is no longer available there. Otherwise, they
would keep using the old image without noticing that it's no longer
updated.

* Remove btrfs-progs and add pigz for faster docker pulls (felipecrs#96)

* Remove non-generic packages from image but add pkgx (felipecrs#97)

* Set docker daemon log-level to warn by default (felipecrs#98)

And remove deprecated fix-attrs.

* Use same JDK as jenkins/inbound-agent (upgrade to 17) (felipecrs#89)

* Add automatic tests (felipecrs#59)

* Add support for `arm64` architecture (felipecrs#75)

* Add Oh My Bash and nano to make debugging the container easier (felipecrs#99)

* Add mention to pkgx and sshd into README

* Allow to run with docker on docker mode (felipecrs#100)

* Setup dond-shim when running in docker on docker mode (felipecrs#101)

* Configure Renovate (felipecrs#102)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Felipe Santos <[email protected]>

* Format json files

* Enable Renovate automerge and dependency dashboard

* Remove nightly docker tags and other dev improvements

* Fix build and Renovate regex

* Reorganize README

* Allow to run as a devcontainer (felipecrs#104)

* Configure Renovate to update Docker (felipecrs#106)

* Update dependency felipecrs/fixdockergid to v0.7.1

* Update dependency docker/buildx to v0.13.0

* Update dependency moby/moby to v25.0.4 (felipecrs#110)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* Update dependency docker/compose to v2.24.7 (felipecrs#108)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Felipe Santos <[email protected]>

* Update ubuntu Docker tag to jammy-20240227 (felipecrs#111)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Felipe Santos <[email protected]>

* Fix shell in intermediate stage

* Update dependency jenkinsci/docker-agent to v3206.vb_15dcf73f6a_9-5

* Refactor legacy s6-overlay services.d into s6-rc.d (felipecrs#114)

* Set startup time per s6-overlay service (felipecrs#115)

* Split image into devcontainer and jenkins-agent-dind (felipecrs#117)

* Fix paths in renovate.json after rename [skip ci]

* Fix image push

* Fix image push (again)

* Update dependency jenkinsci/docker-agent to v3206.vb_15dcf73f6a_9-6

* Update dependency jenkinsci/docker-agent to v3206.vb_15dcf73f6a_9-7

* Configure GitHub Actions cache (felipecrs#124)

* Update dependency moby/moby to v25.0.5

* Update dependency docker/compose to v2.25.0

* Update dependency docker/buildx to v0.13.1 (felipecrs#118)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Felipe Santos <[email protected]>

* Only pin docker-ce version (felipecrs#127)

* Retain USER and HOME env vars when running with docker exec

* Add tests for USER env var

* Reduce sleeps

* Check docker socket through mountpoint

* Speed up Jenkins startup in test

* Fix devcontainer not running entrypoint

* Fix description label of the images

* Fix build cache in CI not being used properly

Refs docker/buildx#1044

* Update jenkins/jenkins Docker tag to v2.440.2

* Combine dockerfiles to improve caching (felipecrs#130)

Because apparently bake does not cache linked build contexts.

* Update dependency moby/moby to v26 (felipecrs#131)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* Fix images description in ghcr.io (felipecrs#133)

* Add test for SSHD in devcontainer (felipecrs#135)

* Test scripted pipeline mounting ~/.m2 (felipecrs#136)

* Ship a better default Dockerfile `SHELL` (felipecrs#137)

* Update dependency moby/moby to v26.0.1

* Update ubuntu Docker tag to jammy-20240405

* Update jenkins/jenkins Docker tag to v2.440.3

* Update dependency moby/moby to v26.0.2

* Update dependency moby/moby to v26.1.0

* Update ubuntu Docker tag to jammy-20240416

* Update Ubuntu 22.04 to 24.04 (felipecrs#144)

* Add Volta back as a pkgx stub (felipecrs#146)

* Move Volta stub to ~/.local/bin instead of /usr/local/bin (felipecrs#148)

* Add python3 and pipx (felipecrs#149)

* Update dependency moby/moby to v26.1.1

* Update ubuntu Docker tag to noble-20240429

* Prefer volta binaries over pkgx ones if available (felipecrs#152)

* Inherit DOMAIN from parent container for /ssh-command/get.sh (felipecrs#153)

* Update dependency moby/moby to v26.1.2

* Update Jenkins Agent JDK from 17 to 21 (felipecrs#155)

* Bypass dind hack when running with Sysbox (felipecrs#156)

* Add wget back to devcontainer and jenkins-agent-dind

Wget was part of v1, but was unintentionally removed in v2.

* Update dependency jenkinsci/helm-charts to v5.1.13

* Update dependency jenkinsci/helm-charts to v5.1.15

* Update dependency jenkinsci/helm-charts to v5.1.16

* Update dependency moby/moby to v26.1.3

* Update dependency jenkinsci/helm-charts to v5.1.17

* Update dependency jenkinsci/helm-charts to v5.1.18

* Update dependency jenkinsci/helm-charts to v5.1.20

* Update dependency jenkinsci/helm-charts to v5.1.21

* Update dependency jenkinsci/helm-charts to v5.1.22

* Update dependency jenkinsci/helm-charts to v5.1.23

* Update dependency jenkinsci/helm-charts to v5.1.24

* Update dependency jenkinsci/helm-charts to v5.1.25

* Update dependency jenkinsci/helm-charts to v5.1.26

* Update ubuntu Docker tag to noble-20240530

* Update dependency moby/moby to v26.1.4

* Update dependency jenkinsci/helm-charts to v5.1.28

* Update dependency jenkinsci/helm-charts to v5.1.29

* Update dependency jenkinsci/helm-charts to v5.1.30

* Update dependency jenkinsci/helm-charts to v5.1.31

* Update dependency jenkinsci/helm-charts to v5.2.0

* Update dependency jenkinsci/helm-charts to v5.2.1

* Update dependency jenkinsci/helm-charts to v5.2.2

* Update docker/bake-action action to v5 (felipecrs#179)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* Update ubuntu Docker tag to noble-20240605

* Update dependency jenkinsci/helm-charts to v5.3.0

* Update dependency jenkinsci/helm-charts to v5.3.1

* Update dependency moby/moby to v27 (felipecrs#183)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* Update dependency moby/moby to v27.0.2

* Use my pkgx fork while main repo is inactive (felipecrs#185)

* Update dependency jenkinsci/helm-charts to v5.3.2

* Update dependency jenkinsci/helm-charts to v5.3.3

* Create FUNDING.yml

* Update dependency felipecrs/pkgx to 1.2.0-felipecrs.1 (felipecrs#189)

* Update dependency moby/moby to v27.0.3

* Improve Renovate depNames

* Try to fix Renovate for felipecrs/pkgx

* Remove unnecessary Renovate config for felipecrs/pkgx

* Update dependency felipecrs/pkgx to v1.2.0-felipecrs.2

* Update dependency jenkinsci/helm-charts to v5.3.6

* Update dependency jenkinsci/helm-charts to v5.4.1

* Update dependency jenkinsci/helm-charts to v5.4.2

* Update dependency jenkinsci/helm-charts to v5.4.3

* Update dependency docker to v27.1.0

* Update dependency docker to v27.1.1

* update ci

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: Felipe Santos <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
maayanyosef added a commit to explorium-ai/jenkins-agent-dind that referenced this issue Jul 28, 2024
* Downgrade docker compose from 2.19.1 to 2.18.1

Because of docker/compose#10751

* Revert "Downgrade docker compose from 2.19.1 to 2.18.1"

Because docker compose 2.20.2 solves the issue.

This reverts commit d0e25e5.

* Downgrade JDK from 11.0.20 to to 11.0.19 (felipecrs#76)

* Align remoting version with jenkins/docker-agent

So we don't try to use non-tested versions of the remoting library.

Also adds some dependencies from jenkins/docker-agent that were missing
in this image.

* Bump dind hack to latest version

* Clean not needed data like man pages

* Switch skopeo installation to skopeo-bin

* Upgrade fixuid from 0.5.1 to 0.6.0

* Add retry (felipecrs#80)

* Fix some hadolint issues

* Bump actions/checkout from 3 to 4 (felipecrs#81)

Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](actions/checkout@v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump docker/metadata-action from 4 to 5 (felipecrs#85)

Bumps [docker/metadata-action](https://github.com/docker/metadata-action) from 4 to 5.
- [Release notes](https://github.com/docker/metadata-action/releases)
- [Upgrade guide](https://github.com/docker/metadata-action/blob/master/UPGRADE.md)
- [Commits](docker/metadata-action@v4...v5)

---
updated-dependencies:
- dependency-name: docker/metadata-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump docker/build-push-action from 4 to 5 (felipecrs#84)

Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 4 to 5.
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](docker/build-push-action@v4...v5)

---
updated-dependencies:
- dependency-name: docker/build-push-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump docker/login-action from 2 to 3 (felipecrs#83)

Bumps [docker/login-action](https://github.com/docker/login-action) from 2 to 3.
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](docker/login-action@v2...v3)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump docker/setup-buildx-action from 2 to 3 (felipecrs#82)

Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 2 to 3.
- [Release notes](https://github.com/docker/setup-buildx-action/releases)
- [Commits](docker/setup-buildx-action@v2...v3)

---
updated-dependencies:
- dependency-name: docker/setup-buildx-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Honor default shell in /ssh-command/get.sh

* Upgrade s6-overlay from v2 to v3 (felipecrs#78)

* Revert "Downgrade JDK from 11.0.20 to to 11.0.19 (felipecrs#76)" (felipecrs#86)

This reverts commit 0c9a5a9.

* Revert "Upgrade s6-overlay from v2 to v3 (felipecrs#78)"

This reverts commit b074844, due to
just-containers/s6-overlay#558.

* Upgrade s6-overlay from v2 to v3 (felipecrs#78)""

This reverts commit 70ec592.

Refs felipecrs#78
Refs just-containers/s6-overlay#558 (comment)

* Downgrade and pin Node.js to v18 (felipecrs#90)

* Bump peter-evans/dockerhub-description from 3 to 4 (felipecrs#91)

Bumps [peter-evans/dockerhub-description](https://github.com/peter-evans/dockerhub-description) from 3 to 4.
- [Release notes](https://github.com/peter-evans/dockerhub-description/releases)
- [Commits](peter-evans/dockerhub-description@v3...v4)

---
updated-dependencies:
- dependency-name: peter-evans/dockerhub-description
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Update Ubuntu 20.04 to 22.04

* Fix minor README issues (felipecrs#93)

* Extract image preparation into a separate script and improve it (felipecrs#94)

Among other things, the new script no longer needs add-apt-repository,
changes the kubernetes debian repository to the new one.

As part of this improvement, we also change the base image from
buildpack to ubuntu, while still keeping the build-essential package
installed. This allows to trim the image size a little bit.

* Stop publishing to Docker Hub (felipecrs#95)

I prefer to concentrate on publishing to GitHub Container Registry, so
that I don't need to maintain two accounts and also because this way all
download counts are in one place.

As part of this change, I also removed the Docker image from Docker Hub,
so that when users try to download it again, it will fail and therefore
notice that the image is no longer available there. Otherwise, they
would keep using the old image without noticing that it's no longer
updated.

* Remove btrfs-progs and add pigz for faster docker pulls (felipecrs#96)

* Remove non-generic packages from image but add pkgx (felipecrs#97)

* Set docker daemon log-level to warn by default (felipecrs#98)

And remove deprecated fix-attrs.

* Use same JDK as jenkins/inbound-agent (upgrade to 17) (felipecrs#89)

* Add automatic tests (felipecrs#59)

* Add support for `arm64` architecture (felipecrs#75)

* Add Oh My Bash and nano to make debugging the container easier (felipecrs#99)

* Add mention to pkgx and sshd into README

* Allow to run with docker on docker mode (felipecrs#100)

* Setup dond-shim when running in docker on docker mode (felipecrs#101)

* Configure Renovate (felipecrs#102)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Felipe Santos <[email protected]>

* Format json files

* Enable Renovate automerge and dependency dashboard

* Remove nightly docker tags and other dev improvements

* Fix build and Renovate regex

* Reorganize README

* Allow to run as a devcontainer (felipecrs#104)

* Configure Renovate to update Docker (felipecrs#106)

* Update dependency felipecrs/fixdockergid to v0.7.1

* Update dependency docker/buildx to v0.13.0

* Update dependency moby/moby to v25.0.4 (felipecrs#110)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* Update dependency docker/compose to v2.24.7 (felipecrs#108)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Felipe Santos <[email protected]>

* Update ubuntu Docker tag to jammy-20240227 (felipecrs#111)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Felipe Santos <[email protected]>

* Fix shell in intermediate stage

* Update dependency jenkinsci/docker-agent to v3206.vb_15dcf73f6a_9-5

* Refactor legacy s6-overlay services.d into s6-rc.d (felipecrs#114)

* Set startup time per s6-overlay service (felipecrs#115)

* Split image into devcontainer and jenkins-agent-dind (felipecrs#117)

* Fix paths in renovate.json after rename [skip ci]

* Fix image push

* Fix image push (again)

* Update dependency jenkinsci/docker-agent to v3206.vb_15dcf73f6a_9-6

* Update dependency jenkinsci/docker-agent to v3206.vb_15dcf73f6a_9-7

* Configure GitHub Actions cache (felipecrs#124)

* Update dependency moby/moby to v25.0.5

* Update dependency docker/compose to v2.25.0

* Update dependency docker/buildx to v0.13.1 (felipecrs#118)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Felipe Santos <[email protected]>

* Only pin docker-ce version (felipecrs#127)

* Retain USER and HOME env vars when running with docker exec

* Add tests for USER env var

* Reduce sleeps

* Check docker socket through mountpoint

* Speed up Jenkins startup in test

* Fix devcontainer not running entrypoint

* Fix description label of the images

* Fix build cache in CI not being used properly

Refs docker/buildx#1044

* Update jenkins/jenkins Docker tag to v2.440.2

* Combine dockerfiles to improve caching (felipecrs#130)

Because apparently bake does not cache linked build contexts.

* Update dependency moby/moby to v26 (felipecrs#131)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* Fix images description in ghcr.io (felipecrs#133)

* Add test for SSHD in devcontainer (felipecrs#135)

* Test scripted pipeline mounting ~/.m2 (felipecrs#136)

* Ship a better default Dockerfile `SHELL` (felipecrs#137)

* Update dependency moby/moby to v26.0.1

* Update ubuntu Docker tag to jammy-20240405

* Update jenkins/jenkins Docker tag to v2.440.3

* Update dependency moby/moby to v26.0.2

* Update dependency moby/moby to v26.1.0

* Update ubuntu Docker tag to jammy-20240416

* Update Ubuntu 22.04 to 24.04 (felipecrs#144)

* Add Volta back as a pkgx stub (felipecrs#146)

* Move Volta stub to ~/.local/bin instead of /usr/local/bin (felipecrs#148)

* Add python3 and pipx (felipecrs#149)

* Update dependency moby/moby to v26.1.1

* Update ubuntu Docker tag to noble-20240429

* Prefer volta binaries over pkgx ones if available (felipecrs#152)

* Inherit DOMAIN from parent container for /ssh-command/get.sh (felipecrs#153)

* Update dependency moby/moby to v26.1.2

* Update Jenkins Agent JDK from 17 to 21 (felipecrs#155)

* Bypass dind hack when running with Sysbox (felipecrs#156)

* Add wget back to devcontainer and jenkins-agent-dind

Wget was part of v1, but was unintentionally removed in v2.

* Update dependency jenkinsci/helm-charts to v5.1.13

* Update dependency jenkinsci/helm-charts to v5.1.15

* Update dependency jenkinsci/helm-charts to v5.1.16

* Update dependency moby/moby to v26.1.3

* Update dependency jenkinsci/helm-charts to v5.1.17

* Update dependency jenkinsci/helm-charts to v5.1.18

* Update dependency jenkinsci/helm-charts to v5.1.20

* Update dependency jenkinsci/helm-charts to v5.1.21

* Update dependency jenkinsci/helm-charts to v5.1.22

* Update dependency jenkinsci/helm-charts to v5.1.23

* Update dependency jenkinsci/helm-charts to v5.1.24

* Update dependency jenkinsci/helm-charts to v5.1.25

* Update dependency jenkinsci/helm-charts to v5.1.26

* Update ubuntu Docker tag to noble-20240530

* Update dependency moby/moby to v26.1.4

* Update dependency jenkinsci/helm-charts to v5.1.28

* Update dependency jenkinsci/helm-charts to v5.1.29

* Update dependency jenkinsci/helm-charts to v5.1.30

* Update dependency jenkinsci/helm-charts to v5.1.31

* Update dependency jenkinsci/helm-charts to v5.2.0

* Update dependency jenkinsci/helm-charts to v5.2.1

* Update dependency jenkinsci/helm-charts to v5.2.2

* Update docker/bake-action action to v5 (felipecrs#179)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* Update ubuntu Docker tag to noble-20240605

* Update dependency jenkinsci/helm-charts to v5.3.0

* Update dependency jenkinsci/helm-charts to v5.3.1

* Update dependency moby/moby to v27 (felipecrs#183)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* Update dependency moby/moby to v27.0.2

* Use my pkgx fork while main repo is inactive (felipecrs#185)

* Update dependency jenkinsci/helm-charts to v5.3.2

* Update dependency jenkinsci/helm-charts to v5.3.3

* Create FUNDING.yml

* Update dependency felipecrs/pkgx to 1.2.0-felipecrs.1 (felipecrs#189)

* Update dependency moby/moby to v27.0.3

* Improve Renovate depNames

* Try to fix Renovate for felipecrs/pkgx

* Remove unnecessary Renovate config for felipecrs/pkgx

* Update dependency felipecrs/pkgx to v1.2.0-felipecrs.2

* Update dependency jenkinsci/helm-charts to v5.3.6

* Update dependency jenkinsci/helm-charts to v5.4.1

* Update dependency jenkinsci/helm-charts to v5.4.2

* Update dependency jenkinsci/helm-charts to v5.4.3

* Update dependency docker to v27.1.0

* Update dependency docker to v27.1.1

* update ci

* Update README.md

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: Felipe Santos <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
kosteev pushed a commit to kosteev/composer-airflow-test-copybara that referenced this issue Sep 12, 2024
This is another attempt to improve caching performance for
multi-platform images as the previous ones were undermined by a
bug in buildx multiplatform cache-to implementattion that caused
the image cache to be overwritten between platforms,
when multiple images were build.

The bug is created for the buildx behaviour at
docker/buildx#1044 and until it is fixed
we have to prpare separate caches for each platform and push them
to separate tags.

That adds a bit overhead on the building step, but for now it is
the simplest way we can workaround the bug if we do not want to
manually manipulate manifests and images.

(cherry picked from commit 9a6baab5a271b28b6b3cbf96ffa151ac7dc79013)

GitOrigin-RevId: 9809ad75b6528ed3b8f307cb8dc15aafefc93169
kosteev pushed a commit to GoogleCloudPlatform/composer-airflow that referenced this issue Sep 18, 2024
This is another attempt to improve caching performance for
multi-platform images as the previous ones were undermined by a
bug in buildx multiplatform cache-to implementattion that caused
the image cache to be overwritten between platforms,
when multiple images were build.

The bug is created for the buildx behaviour at
docker/buildx#1044 and until it is fixed
we have to prpare separate caches for each platform and push them
to separate tags.

That adds a bit overhead on the building step, but for now it is
the simplest way we can workaround the bug if we do not want to
manually manipulate manifests and images.

GitOrigin-RevId: 9a6baab5a271b28b6b3cbf96ffa151ac7dc79013
kosteev pushed a commit to GoogleCloudPlatform/composer-airflow that referenced this issue Nov 7, 2024
This is another attempt to improve caching performance for
multi-platform images as the previous ones were undermined by a
bug in buildx multiplatform cache-to implementattion that caused
the image cache to be overwritten between platforms,
when multiple images were build.

The bug is created for the buildx behaviour at
docker/buildx#1044 and until it is fixed
we have to prpare separate caches for each platform and push them
to separate tags.

That adds a bit overhead on the building step, but for now it is
the simplest way we can workaround the bug if we do not want to
manually manipulate manifests and images.

GitOrigin-RevId: 9a6baab5a271b28b6b3cbf96ffa151ac7dc79013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

9 participants