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

Only run separate per-platform build when preparing build cache #24023

Merged
merged 1 commit into from
May 30, 2022

Commits on May 30, 2022

  1. Only run separate per-platform build when preparing build cache

    Apparently pushing multi-platform images when building cache on CI
    has some problems recently, connected with ghcr.io being more
    vulnerable to race condition described in this issue:
    
    containerd/containerd#5978
    
    Apparently when two, different platform layers are pushed about
    the same time to ghcr.io, the error
    "cannot reuse body, request must be retried" is generated.
    
    However we actually do not even need to build the multiplatform
    latest images because as of recently we have separate cache for each
    platform, and the ghcr.io/:latest images are not used any more
    not even for docker builds. We we always build images rather than
    pull and we use --from-cache for that - specific per platform. The only
    image pulling we do is when we pull the :COMMIT_HASH images in CI- but
    those are single-platform images (amd64) and even if we add tests for
    arm, they will have different tag.
    
    Hopefully we can still build release images without causing the
    race condition too frequently - this is more likely because when
    we build images for cache we use machines with different performance
    characteristics and the same layers are pushed at different times
    from different platforms.
    potiuk committed May 30, 2022
    Configuration menu
    Copy the full SHA
    b165cc9 View commit details
    Browse the repository at this point in the history