devops(docker): split browser layers and use zstd compression for faster pulls#40702
Open
KRRT7 wants to merge 4 commits intomicrosoft:mainfrom
Open
devops(docker): split browser layers and use zstd compression for faster pulls#40702KRRT7 wants to merge 4 commits intomicrosoft:mainfrom
KRRT7 wants to merge 4 commits intomicrosoft:mainfrom
Conversation
The zstd compression output requires a buildx builder with the docker-container driver. Also removes the now-unused tag_and_push function.
Build pushes one canonical tag per arch, then tag_and_push creates additional tags via `docker buildx imagetools create` (registry-side copy, no layer re-upload).
Use `install-deps` for all system dependencies in one shared layer, then `install` (without --with-deps) per browser for binary-only layers. This eliminates duplicate apt index fetches and makes browser layers pure binary data with better zstd compression ratio.
Member
|
Thanks for looking into it. I'm sure we have customers with older docker clients. But I'm ok with the layering change. Could you provide the numbers? Time w/ and w/o layers next to each other. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
RUNinto per-browser layers (chromium, firefox, webkit, ffmpeg) enabling Docker's parallel layer downloadingdocker build+docker pushtodocker buildx build --pushwith zstd compression (level 19) for ~25% smaller compressed layersdocker buildx imagetools create(registry-side copy, no layer re-upload)docker/setup-buildx-actionto CI (required for buildx + zstd output)Note on zstd compatibility
zstd-compressed layers require Docker 23.0+ (Feb 2023) on the client side. Older Docker versions will fail to pull. If this is a concern for your user base, the layer-splitting alone still provides a significant speedup via parallel downloads, and the zstd change could be dropped or deferred.
Fixes #40701