aboutsummaryrefslogtreecommitdiff
path: root/cmd/podman/common
diff options
context:
space:
mode:
authorDaniel J Walsh <dwalsh@redhat.com>2021-02-26 06:35:39 -0500
committerDaniel J Walsh <dwalsh@redhat.com>2021-02-26 06:37:48 -0500
commit680dacaea2c7c8150cb2a8c9770a6e981a1f5ebc (patch)
treef9e448591b1562dc7d1f1dffa6dc8bfaf0c21c9b /cmd/podman/common
parent05410e81efec2ef2398f740b81610fbad73b7bf2 (diff)
downloadpodman-680dacaea2c7c8150cb2a8c9770a6e981a1f5ebc.tar.gz
podman-680dacaea2c7c8150cb2a8c9770a6e981a1f5ebc.tar.bz2
podman-680dacaea2c7c8150cb2a8c9770a6e981a1f5ebc.zip
Enable no_hosts from containers.conf
Since we have no good way to enable this on the server side, we will just allow it to be set on the client side. This should solve almost all cases. Partially fixes: https://github.com/containers/podman/issues/9500 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Diffstat (limited to 'cmd/podman/common')
-rw-r--r--cmd/podman/common/netflags.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd/podman/common/netflags.go b/cmd/podman/common/netflags.go
index bc4d54de0..4d0a554a6 100644
--- a/cmd/podman/common/netflags.go
+++ b/cmd/podman/common/netflags.go
@@ -80,7 +80,7 @@ func DefineNetFlags(cmd *cobra.Command) {
_ = cmd.RegisterFlagCompletionFunc(publishFlagName, completion.AutocompleteNone)
netFlags.Bool(
- "no-hosts", false,
+ "no-hosts", containerConfig.Containers.NoHosts,
"Do not create /etc/hosts within the container, instead use the version from the image",
)
}