Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: update network description #2343

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 11 additions & 7 deletions docs/containers.conf.5.md
Original file line number Diff line number Diff line change
Expand Up @@ -304,13 +304,12 @@ Specified as "type=TYPE,source=<directory-on-host>,destination=<directory-in-con

Example: [ "type=bind,source=/var/lib/foobar,destination=/var/lib/foobar,ro", ]

**netns**="private"
**netns**=""

Default way to create a NET namespace for the container.
Options are:
`private` Create private NET Namespace for the container.
`host` Share host NET Namespace with the container.
`none` Containers do not use the network.
The option is mapped to the **--network** argument for the podman commands, it accepts the same values as that option.
For example it can be set to `bridge`, `host`, `none`, `pasta` and more, see the [podman-create(1)](https://docs.podman.io/en/latest/markdown/podman-create.1.html#network-mode-net)
manual for all available options.

**no_hosts**=false

Expand Down Expand Up @@ -442,12 +441,17 @@ netavark_plugin_dirs = [

**default_network**="podman"

The network name of the default network to attach pods to.
The name of the default network as seen in `podman network ls`. This option only effects the network assignment when
the bridge network mode is selected, i.e. `--network bridge`. It is the default for rootful containers but not as
rootless. To change the default network mode use the **netns** option under the `[containers]` table.

Note: This should not be changed while you have any containers using this network.

**default_subnet**="10.88.0.0/16"

The subnet to use for the default network (named above in **default_network**).
If the default network does not exist, it will be automatically created the first time a tool is run using this subnet.

Note: This should not be changed if any containers are currently running on the default network.

**default_subnet_pools**=[]

Expand Down
24 changes: 13 additions & 11 deletions pkg/config/containers.conf
Original file line number Diff line number Diff line change
Expand Up @@ -236,13 +236,12 @@ default_sysctls = [
#
#mounts = []

# Default way to to create a Network namespace for the container
# Options are:
# `private` Create private Network Namespace for the container.
# `host` Share host Network Namespace with the container.
# `none` Containers do not use the network
# Default way to create a NET namespace for the container.
# The option is mapped to the **--network** argument for the podman commands, it accepts the same values as that option.
# For example it can be set to `bridge`, `host`, `none`, `pasta` and more, see the podman-create(1)
# manual for all available options.
#
#netns = "private"
#netns = ""

# Do not modify the `/etc/hosts` file in the container. Podman assumes control
# over the container's `/etc/hosts` file by default; refer to the `--add-host`
Expand Down Expand Up @@ -381,14 +380,17 @@ default_sysctls = [
#firewall_driver = ""


# The network name of the default network to attach pods to.
# The name of the default network as seen in `podman network ls`. This option only effects the network assignment when
# the bridge network mode is selected, i.e. `--network bridge`. It is the default for rootful containers but not as
# rootless. To change the default network mode use the **netns** option under the `[containers]` table.
#
# Note: This should not be changed while you have any containers using this network.
#
#default_network = "podman"

# The default subnet for the default network given in default_network.
# If a network with that name does not exist, a new network using that name and
# this subnet will be created.
# Must be a valid IPv4 CIDR prefix.
#
# Note: This should not be changed if any containers are currently running on the default network.
#
#default_subnet = "10.88.0.0/16"

Expand Down Expand Up @@ -897,7 +899,7 @@ default_sysctls = [
# Linux:
# qemu - Open source machine emulator and virtualizer. (Default)
# Windows: there are currently two options:
# wsl - Windows Subsystem for Linux (Default)
# wsl - Windows Subsystem for Linux (Default)
# hyperv - Windows Server Virtualization
# Mac: there are currently two options:
# applehv - Default Apple Hypervisor (Default)
Expand Down
22 changes: 12 additions & 10 deletions pkg/config/containers.conf-freebsd
Original file line number Diff line number Diff line change
Expand Up @@ -182,13 +182,12 @@ default_sysctls = [
#
#log_tag = ""

# Default way to to create a Network namespace for the container
# Options are:
# `private` Create private Network Namespace for the container.
# `host` Share host Network Namespace with the container.
# `none` Containers do not use the network
# Default way to create a NET namespace for the container.
# The option is mapped to the **--network** argument for the podman commands, it accepts the same values as that option.
# For example it can be set to `bridge`, `host`, `none`, `pasta` and more, see the podman-create(1)
# manual for all available options.
#
#netns = "private"
#netns = ""

# Create /etc/hosts for the container. By default, container engine manage
# /etc/hosts, automatically adding the container's own IP address.
Expand Down Expand Up @@ -292,14 +291,17 @@ default_sysctls = [
# "/usr/lib/netavark",
#]

# The network name of the default network to attach pods to.
# The name of the default network as seen in `podman network ls`. This option only effects the network assignment when
# the bridge network mode is selected, i.e. `--network bridge`. It is the default for rootful containers but not as
# rootless. To change the default network mode use the **netns** option under the `[containers]` table.
#
# Note: This should not be changed while you have any containers using this network.
#
#default_network = "podman"

# The default subnet for the default network given in default_network.
# If a network with that name does not exist, a new network using that name and
# this subnet will be created.
# Must be a valid IPv4 CIDR prefix.
#
# Note: This should not be changed if any containers are currently running on the default network.
#
#default_subnet = "10.88.0.0/16"

Expand Down