summaryrefslogtreecommitdiff
path: root/cmd/podman/registry
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/podman/registry')
-rw-r--r--cmd/podman/registry/remote.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/cmd/podman/registry/remote.go b/cmd/podman/registry/remote.go
index 9b7523ac0..78b820269 100644
--- a/cmd/podman/registry/remote.go
+++ b/cmd/podman/registry/remote.go
@@ -15,13 +15,14 @@ var remoteFromCLI = struct {
}{}
// IsRemote returns true if podman was built to run remote or --remote flag given on CLI
-// Use in init() functions as a initialization check
+// Use in init() functions as an initialization check
func IsRemote() bool {
remoteFromCLI.sync.Do(func() {
fs := pflag.NewFlagSet("remote", pflag.ContinueOnError)
- fs.BoolVarP(&remoteFromCLI.Value, "remote", "r", false, "")
fs.ParseErrorsWhitelist.UnknownFlags = true
+ fs.Usage = func() {}
fs.SetInterspersed(false)
+ fs.BoolVarP(&remoteFromCLI.Value, "remote", "r", false, "")
_ = fs.Parse(os.Args[1:])
})
return podmanOptions.EngineMode == entities.TunnelMode || remoteFromCLI.Value