diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2022-02-21 15:33:39 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-21 15:33:39 -0500 |
commit | a746a61a171d514947dbd4db88541e3702647f2d (patch) | |
tree | e06d4071d59ec0dc73b12a37fd4626b7209af6b1 /cmd/podman | |
parent | c3a9505232d88a6133b5c65de008d6a30099ea55 (diff) | |
parent | 9ce61e3a4911ad89151788539f10d96f69362bc3 (diff) | |
download | podman-a746a61a171d514947dbd4db88541e3702647f2d.tar.gz podman-a746a61a171d514947dbd4db88541e3702647f2d.tar.bz2 podman-a746a61a171d514947dbd4db88541e3702647f2d.zip |
Merge pull request #13286 from flouthoc/kube-build-false-default
kube: honor `--build=false` if specified.
Diffstat (limited to 'cmd/podman')
-rw-r--r-- | cmd/podman/play/kube.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/cmd/podman/play/kube.go b/cmd/podman/play/kube.go index ccf6ea861..1a430f2dc 100644 --- a/cmd/podman/play/kube.go +++ b/cmd/podman/play/kube.go @@ -27,6 +27,7 @@ type playKubeOptionsWrapper struct { TLSVerifyCLI bool CredentialsCLI string StartCLI bool + BuildCLI bool } var ( @@ -117,7 +118,7 @@ func init() { _ = kubeCmd.RegisterFlagCompletionFunc(configmapFlagName, completion.AutocompleteDefault) buildFlagName := "build" - flags.BoolVar(&kubeOptions.Build, buildFlagName, false, "Build all images in a YAML (given Containerfiles exist)") + flags.BoolVar(&kubeOptions.BuildCLI, buildFlagName, false, "Build all images in a YAML (given Containerfiles exist)") } if !registry.IsRemote() { @@ -138,6 +139,9 @@ func kube(cmd *cobra.Command, args []string) error { if cmd.Flags().Changed("start") { kubeOptions.Start = types.NewOptionalBool(kubeOptions.StartCLI) } + if cmd.Flags().Changed("build") { + kubeOptions.Build = types.NewOptionalBool(kubeOptions.BuildCLI) + } if kubeOptions.Authfile != "" { if _, err := os.Stat(kubeOptions.Authfile); err != nil { return err |