Skip to content

Commit

Permalink
Merge pull request #5755 from k9withabone/manifest-push-all
Browse files Browse the repository at this point in the history
Make `buildah manifest push --all` true by default
  • Loading branch information
openshift-merge-bot[bot] authored Oct 3, 2024
2 parents 322425b + d081959 commit bd0de14
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cmd/buildah/manifest.go
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ func init() {
manifestPushCommand.SetUsageTemplate(UsageTemplate())
flags = manifestPushCommand.Flags()
flags.BoolVar(&manifestPushOpts.rm, "rm", false, "remove the manifest list if push succeeds")
flags.BoolVar(&manifestPushOpts.all, "all", false, "also push the images in the list")
flags.BoolVar(&manifestPushOpts.all, "all", true, "also push the images in the list")
flags.StringVar(&manifestPushOpts.authfile, "authfile", auth.GetDefaultAuthFile(), "path of the authentication file. Use REGISTRY_AUTH_FILE environment variable to override")
flags.StringVar(&manifestPushOpts.certDir, "cert-dir", "", "use certificates at the specified path to access the registry")
flags.StringVar(&manifestPushOpts.creds, "creds", "", "use `[username[:password]]` for accessing the registry")
Expand Down
2 changes: 1 addition & 1 deletion docs/buildah-manifest-push.1.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ original instance.
**--all**

Push the images mentioned in the manifest list or image index, in addition to
the list or index itself.
the list or index itself. (Default true)

**--authfile** *path*

Expand Down
5 changes: 5 additions & 0 deletions tests/lists.bats
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,11 @@ IMAGE_LIST_S390X_INSTANCE_DIGEST=sha256:882a20ee0df7399a445285361d38b711c299ca09
expect_output --substring ${IMAGE_LIST_S390X_INSTANCE_DIGEST##sha256:}
}

@test "manifest-push-all-default-true" {
run_buildah manifest push --help
expect_output --substring "all.*\(default true\).*authfile"
}

@test "manifest-push-purge" {
run_buildah manifest create foo
run_buildah manifest add --arch=arm64 foo ${IMAGE_LIST}
Expand Down

1 comment on commit bd0de14

@packit-as-a-service
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

podman-next COPR build failed. @containers/packit-build please check.

Please sign in to comment.