Skip to content

Can I build with multiple compression types? #2977

Answered by tonistiigi
gapuchi asked this question in Q&A
Discussion options

You must be logged in to vote

There is no way to specify multiple compression types for same build.

When builds are invoked in parallel(second invoked before first completes) they are guaranteed to get the same base image.

Other option is to use buildx bake with a context pointing to the previous build that just returns the context itself. Then you can have many bake targets with their own exporter options building the same thing. Last section https://www.docker.com/blog/dockerfiles-now-support-multiple-build-contexts/

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@jedevc
Comment options

jedevc Jul 22, 2022
Collaborator

@gapuchi
Comment options

@tonistiigi
Comment options

@gapuchi
Comment options

Answer selected by gapuchi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants