Skip to content

feat: Adding platform flag to image download - #10853

Open
geoffo-dev wants to merge 3 commits into
aws:mainfrom
geoffo-dev:main
Open

geoffo-dev wants to merge 3 commits into
aws:mainfrom
geoffo-dev:main

Conversation

@geoffo-dev

Copy link
Copy Markdown

Issue #, if available:

Description of changes:

This will allow machines such as macs to download images in a different architecture for airgapped environments.

Testing (if applicable):

Have built the cli tool and have run the download option with the platform flag. This has produced an images.tar file which contains amd images on an arm machine.

Documentation added/planned (if applicable):

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

claude and others added 3 commits July 11, 2026 15:56
The download images command pulls images with the host's default
platform, so running it on an arm64 machine (e.g. Apple Silicon Mac)
produces an air-gapped tarball of arm64 images even when the target
cluster is amd64. Add a --platform flag (e.g. linux/amd64) that is
passed through to docker pull so users can choose the architecture of
the downloaded images.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019dfddgR1ZFJyiWsQpchA1U
The --platform flag only reached `docker pull`; the tarball is written by
`docker save`, which kept exporting the host platform. With the containerd
image store, `docker pull --platform` fetches only the requested arch's blobs,
so a plain `docker save` exports a multi-arch index it can't resolve and fails
(or exports the wrong arch) — the downloaded images were not the requested
platform.

Thread the platform through ImageDiskDestination -> SaveToFile so
`download images --platform linux/amd64` runs `docker save --platform
linux/amd64`, mirroring the option pattern already used on the source side.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Add --platform flag to download images for cross-arch airgapped bundles - this should allow arm machines to pull amd images for upload to a remote server.
@eks-distro-bot

Copy link
Copy Markdown
Collaborator

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign parlakisik for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@eks-distro-bot eks-distro-bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. needs-ok-to-test labels Jul 12, 2026
@eks-distro-bot

Copy link
Copy Markdown
Collaborator

Hi @geoffo-dev. Thanks for your PR.

I'm waiting for a aws member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work.

Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-ok-to-test size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants