diff --git a/cmd/podman/root.go b/cmd/podman/root.go index 910ee8e594..d01b1eb6db 100644 --- a/cmd/podman/root.go +++ b/cmd/podman/root.go @@ -457,6 +457,7 @@ func rootFlags(cmd *cobra.Command, podmanConfig *entities.PodmanConfig) { namespaceFlagName := "namespace" pFlags.StringVar(&podmanConfig.ContainersConf.Engine.Namespace, namespaceFlagName, podmanConfig.ContainersConfDefaultsRO.Engine.Namespace, "Set the libpod namespace, used to create separate views of the containers and pods on the system") _ = cmd.RegisterFlagCompletionFunc(namespaceFlagName, completion.AutocompleteNone) + _ = pFlags.MarkHidden(namespaceFlagName) networkBackendFlagName := "network-backend" pFlags.StringVar(&podmanConfig.ContainersConf.Network.NetworkBackend, networkBackendFlagName, podmanConfig.ContainersConfDefaultsRO.Network.NetworkBackend, `Network backend to use ("cni"|"netavark")`) diff --git a/docs/source/markdown/podman.1.md b/docs/source/markdown/podman.1.md index 4e98c2333c..49b8a1d8ee 100644 --- a/docs/source/markdown/podman.1.md +++ b/docs/source/markdown/podman.1.md @@ -82,11 +82,6 @@ Remote connections use local containers.conf for default. Log messages at and above specified level: debug, info, warn, error, fatal or panic (default: "warn") -#### **--namespace**=*namespace* - -Set libpod namespace. Namespaces are used to separate groups of containers and pods in libpod's state. -When namespace is set, created containers and pods will join the given namespace, and only containers and pods in the given namespace will be visible to Podman. - #### **--network-cmd-path**=*path* Path to the command binary to use for setting up a network. It is currently only used for setting up a slirp4netns(1) or pasta(1) network. If "" is used then the binary is looked up using the $PATH environment variable. diff --git a/libpod/boltdb_state.go b/libpod/boltdb_state.go index 3f643d8f16..30a7e4759b 100644 --- a/libpod/boltdb_state.go +++ b/libpod/boltdb_state.go @@ -541,7 +541,7 @@ func (s *BoltState) GetContainerName(id string) (string, error) { } // GetPodName returns the name associated with a given ID. -// Returns ErrNoSuchPor if the ID does not exist. +// Returns ErrNoSuchPod if the ID does not exist. func (s *BoltState) GetPodName(id string) (string, error) { if id == "" { return "", define.ErrEmptyID diff --git a/libpod/runtime.go b/libpod/runtime.go index 6e6c6d1de8..56fc5e0af6 100644 --- a/libpod/runtime.go +++ b/libpod/runtime.go @@ -428,7 +428,7 @@ func makeRuntime(runtime *Runtime) (retErr error) { } if runtime.config.Engine.Namespace != "" { - return fmt.Errorf("namespaces are not supported by this version of Libpod: %w", define.ErrNotImplemented) + return fmt.Errorf("namespaces are not supported by this version of Libpod, please unset the `namespace` field in containers.conf: %w", define.ErrNotImplemented) } needsUserns := os.Geteuid() != 0