From ca9efb0cda26478d51eeb71dd27d0c9a40c5b7b1 Mon Sep 17 00:00:00 2001 From: Paul Holzinger Date: Thu, 19 Oct 2023 13:04:15 +0200 Subject: [PATCH] network: document ports and macvlan interaction The network backend will ignore ports for macvlan and ipvlan networks so they do not do anything. No warning or error is shown because containers may be later connected to a bridge network in which case they would be useful. Fixes #17927 Signed-off-by: Paul Holzinger --- docs/source/markdown/options/publish.md | 3 +++ docs/source/markdown/podman-network-create.1.md | 3 +++ 2 files changed, 6 insertions(+) diff --git a/docs/source/markdown/options/publish.md b/docs/source/markdown/options/publish.md index d9447b558a..dfe8867567 100644 --- a/docs/source/markdown/options/publish.md +++ b/docs/source/markdown/options/publish.md @@ -21,3 +21,6 @@ Host port does not have to be specified (e.g. `podman run -p 127.0.0.1::80`). If it is not, the container port is randomly assigned a port on the host. Use **podman port** to see the actual mapping: `podman port $CONTAINER $CONTAINERPORT`. + +Note that the network drivers `macvlan` and `ipvlan` do not support port forwarding, +it will have no effect on these networks. diff --git a/docs/source/markdown/podman-network-create.1.md b/docs/source/markdown/podman-network-create.1.md index 17832ba1db..ce1da280fe 100644 --- a/docs/source/markdown/podman-network-create.1.md +++ b/docs/source/markdown/podman-network-create.1.md @@ -43,6 +43,9 @@ under the `[network]` section. The name of the plugin can then be used as driver to create a network for your plugin. The list of all supported drivers and plugins can be seen with `podman info --format {{.Plugins.Network}}`. +Note that the `macvlan` and `ipvlan` drivers do not support port forwarding. Support for port forwarding +with a plugin depends on the implementation of the plugin. + #### **--gateway**=*ip* Define a gateway for the subnet. To provide a gateway address, a