potiuk edited a comment on pull request #20664:
URL: https://github.com/apache/airflow/pull/20664#issuecomment-1005562336


   > Whats buildx vs buildkit?
   
   Essentially the same. Buildx is a plugin you can install in docker to get 
more capabilities of buildkit available as "docker buildx build" command (and a 
number of management commands). You do not need it to run "buildkit-enabled" 
builds (`DOCKER_BUILDKIT=1` is enough in docker 1.18+) but you need it for 
example to build and push cache to github registry.
   
   An example of that is our prod image. It is multi-segmented image so in 
order to prepare a good cache for the builds I need to do it with command 
smilar to `docker buildx build . 
--cache-to=type=registry,ref=ghcr.io/,........,mode=max` (mode=max means that 
the cache includes layers from all segments which means that when you build 
muiti-segmented build one --cache-from is enough)  
   
   This was (about a year ago when I checked last time) missing in buildkit - 
you had to do some strange combination of not-yet-released-then tools from 
"moby" to build and refresh the cache- but now with the plugin it's a "breeze" 
to manage and prepare the cache.
   
   In our case users will not have to install buildx plugin, but it will have 
to be available (eventually) on our self-hosted runners to refresh the cache on 
main builds (I will add it) and any time you want to manually refresh the cache 
with `./breeze prepare-build-cache`. 
   
   https://docs.docker.com/engine/reference/commandline/buildx_build/
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to