aboutsummaryrefslogtreecommitdiff
path: root/cmd/podman/manifest/annotate.go
diff options
context:
space:
mode:
authorDaniel J Walsh <dwalsh@redhat.com>2021-01-25 09:41:55 -0500
committerMatthew Heon <matthew.heon@pm.me>2021-02-08 13:58:10 -0500
commit5da474dec055a678a2870e54f017c022ba4bf71a (patch)
treeafaf29504b63317da7e9f0e9f948b63d6bfc63b8 /cmd/podman/manifest/annotate.go
parent7c05d5292b326f6faa0acbe1d7600336f62951c1 (diff)
downloadpodman-5da474dec055a678a2870e54f017c022ba4bf71a.tar.gz
podman-5da474dec055a678a2870e54f017c022ba4bf71a.tar.bz2
podman-5da474dec055a678a2870e54f017c022ba4bf71a.zip
Fix --arch and --os flags to work correctly
Currently podman implements --override-arch and --overide-os But Podman has made these aliases for --arch and --os. No reason to have to specify --override, since it is clear what the user intends. Currently if the user specifies an --override-arch field but the image was previously pulled for a different Arch, podman run uses the different arch. This PR also fixes this issue. Fixes: https://github.com/containers/podman/issues/8001 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Diffstat (limited to 'cmd/podman/manifest/annotate.go')
-rw-r--r--cmd/podman/manifest/annotate.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/cmd/podman/manifest/annotate.go b/cmd/podman/manifest/annotate.go
index 71017e0ec..7c4f5ad01 100644
--- a/cmd/podman/manifest/annotate.go
+++ b/cmd/podman/manifest/annotate.go
@@ -39,7 +39,7 @@ func init() {
archFlagName := "arch"
flags.StringVar(&manifestAnnotateOpts.Arch, archFlagName, "", "override the `architecture` of the specified image")
- _ = annotateCmd.RegisterFlagCompletionFunc(archFlagName, completion.AutocompleteNone)
+ _ = annotateCmd.RegisterFlagCompletionFunc(archFlagName, completion.AutocompleteArch)
featuresFlagName := "features"
flags.StringSliceVar(&manifestAnnotateOpts.Features, featuresFlagName, nil, "override the `features` of the specified image")
@@ -47,7 +47,7 @@ func init() {
osFlagName := "os"
flags.StringVar(&manifestAnnotateOpts.OS, osFlagName, "", "override the `OS` of the specified image")
- _ = annotateCmd.RegisterFlagCompletionFunc(osFlagName, completion.AutocompleteNone)
+ _ = annotateCmd.RegisterFlagCompletionFunc(osFlagName, completion.AutocompleteOS)
osFeaturesFlagName := "os-features"
flags.StringSliceVar(&manifestAnnotateOpts.OSFeatures, osFeaturesFlagName, nil, "override the OS `features` of the specified image")