aboutsummaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2022-05-05 11:17:37 -0400
committerGitHub <noreply@github.com>2022-05-05 11:17:37 -0400
commit8ba679fc37fe62e7af31611e47b09a6c4b11f3a9 (patch)
tree1c30dcaa993f5e106d89cfee11ec5745b5b423f2 /cmd
parent09b8831fa21c47bf1dac05381b61cec0092f94c5 (diff)
parentc38e7e5f6172b5f8728ab03d0d36335aaba53553 (diff)
downloadpodman-8ba679fc37fe62e7af31611e47b09a6c4b11f3a9.tar.gz
podman-8ba679fc37fe62e7af31611e47b09a6c4b11f3a9.tar.bz2
podman-8ba679fc37fe62e7af31611e47b09a6c4b11f3a9.zip
Merge pull request #14125 from flouthoc/podman-remote-doc-build-output
build: disable and hide `--output` for podman-remote clients
Diffstat (limited to 'cmd')
-rw-r--r--cmd/podman/images/build.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/cmd/podman/images/build.go b/cmd/podman/images/build.go
index 1ceb63684..3ea60e18a 100644
--- a/cmd/podman/images/build.go
+++ b/cmd/podman/images/build.go
@@ -190,6 +190,7 @@ func buildFlags(cmd *cobra.Command) {
_ = flags.MarkHidden("tls-verify")
_ = flags.MarkHidden("compress")
_ = flags.MarkHidden("volume")
+ _ = flags.MarkHidden("output")
}
}
@@ -201,6 +202,10 @@ func build(cmd *cobra.Command, args []string) error {
return errors.New("cannot specify --squash, --squash-all and --layers options together")
}
+ if cmd.Flag("output").Changed && registry.IsRemote() {
+ return errors.New("'--output' option is not supported in remote mode")
+ }
+
// Extract container files from the CLI (i.e., --file/-f) first.
var containerFiles []string
for _, f := range buildOpts.File {