mirror of
https://github.com/containers/podman-compose.git
synced 2025-08-18 17:38:34 +02:00
Add support to set --route of podman network create
This is not present in the compose spec. However, netavark podman network backend does support --route option, which is useful for various kinds of things. It is very easy to expose it. Signed-off-by: Povilas Kanapickas <povilas@radix.lt>
This commit is contained in:
@@ -61,6 +61,19 @@ network:
|
||||
- "10.1.2.4"
|
||||
```
|
||||
|
||||
* `x-podman.routes` - Specifies a list of additional routes for the network. This corresponds to
|
||||
`--route` option in `podman network create`.
|
||||
|
||||
For example, the following docker-compose.yml blocks network connectivity to specified subnet from
|
||||
all containers on the network:
|
||||
```yml
|
||||
version: "3"
|
||||
network:
|
||||
my_network:
|
||||
x-podman.routes:
|
||||
- "10.2.3.4,127.0.0.1"
|
||||
```
|
||||
|
||||
For explanations of these extensions, please refer to the
|
||||
[Podman network create command Documentation](https://docs.podman.io/en/latest/markdown/podman-network-create.1.html).
|
||||
|
||||
|
Reference in New Issue
Block a user