moby / buildkit

concurrent, cache-efficient, and Dockerfile-agnostic builder toolkit
https://github.com/moby/moby/issues/34227
Apache License 2.0
8.17k stars 1.16k forks source link

Add Buddy CI/CD as Docker cache #4312

Open Kivlov84 opened 1 year ago

Kivlov84 commented 1 year ago

Hello guys,

We provide CI/CD for web developers: https://buddy.works. Recently, we have delivered a dedicated Docker cache for our customers, which works exactly the same as gha cache.

At the moment, we need to ask our users to set the type to gha:

docker buildx build --push -t <registry>/<image> \
  --cache-to type=gha[,parameters...] \
  --cache-from type=gha[,parameters...] .

Unfortunately, developers are convinced the cache is stored in GitHub Actions, which is misleading when investigating CI/CD issues. This proves a problem, especially in companies where multiple users are engaged in scripting DevOps processes, as they are trying to debug the problem in GHA instead of our cache.

To solve it, we'd like to add bdy as a supported type using a PR to these repositories:

https://github.com/moby/buildkit https://github.com/moby/moby

However, we'd like to know that the PR's will be accepted before we invest our time and resources in development.

Looking forward to your reply.

Alexander

tonistiigi commented 1 year ago

type=gha works on the protocol that Github designed for their cache service. If your implementation is different, then I think the name serves as "gha-compatible". The same situation is with S3 where there are lots of implementations that create S3-compatible API, but they all would need to use the s3 name. From the user's perspective as well it would just increase fragmentation if the same implementation is accessed by different names.

Kivlov84 commented 1 year ago

Thank you for the reply, fair point.

Could we at least add the information about compatibility to the documentation to make it apparent to the users? I mean this spot here: https://docs.docker.com/engine/reference/commandline/buildx_build/#cache-to

Adding compatibility info to S3 would look like this:

The same goes with gha_type:

Also here: https://docs.docker.com/engine/reference/commandline/buildx_build/#cache-from

dvdksn commented 10 months ago

I can add the compatibility clarification in docs

Kivlov84 commented 9 months ago

@dvdksn much appreciated, please do!