Skip to content

docs(cli): note --tarball is single-platform-only - #1727

Open
shivanshu877 wants to merge 1 commit into
ko-build:mainfrom
shivanshu877:docs/1708-tarball-multi-platform
Open

docs(cli): note --tarball is single-platform-only#1727
shivanshu877 wants to merge 1 commit into
ko-build:mainfrom
shivanshu877:docs/1708-tarball-multi-platform

Conversation

@shivanshu877

Copy link
Copy Markdown

Fixes #1708.

The --tarball flag description used to be just "File to save images tarballs", which reads like it works with the same multi-platform builds ko otherwise supports. The tarball publisher only handles v1.Image (single-platform), not v1.ImageIndex — see pkg/publish/tarball.go, which downcasts the build result and rejects an image index with the comment "there is no way to write an index to a tarball".

Change

Extend the flag help to:

  1. Name the format (Docker-save-style),
  2. State the single-platform limitation,
  3. Point users to --oci-layout-path for multi-platform output.

Regenerated the affected docs under docs/reference/ via ./hack/update-codegen.sh. No code behaviour change.

Verification

  • ./hack/presubmit.sh — clean
  • go test ./pkg/commands/options/... — pass
Fixes ko-build#1708.

The --tarball flag description used to be just "File to save images
tarballs", which reads like it works with the same multi-platform builds
ko otherwise supports. The tarball publisher only handles v1.Image
(single-platform), not v1.ImageIndex — see pkg/publish/tarball.go, which
downcasts the build result and rejects an image index with the comment
"there is no way to write an index to a tarball".

Extend the flag help to (a) name the format (Docker-save-style), (b)
state the single-platform limitation, and (c) point users to
--oci-layout-path for multi-platform output. Regenerated the affected
docs under docs/reference/ via ./hack/update-codegen.sh.

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

Labels

None yet

1 participant