summaryrefslogtreecommitdiff
path: root/pkg
diff options
context:
space:
mode:
authorPaul Holzinger <pholzing@redhat.com>2022-01-27 15:13:55 +0100
committerPaul Holzinger <pholzing@redhat.com>2022-01-27 16:38:39 +0100
commit6961d912061c81b7a444e7c00163ae240e318c42 (patch)
tree2949cf26bf6a516da58475064e17c932cf273eb6 /pkg
parent5659b0734c628f3f42fd976b6ce91372be3019ae (diff)
downloadpodman-6961d912061c81b7a444e7c00163ae240e318c42.tar.gz
podman-6961d912061c81b7a444e7c00163ae240e318c42.tar.bz2
podman-6961d912061c81b7a444e7c00163ae240e318c42.zip
network create: allow multiple subnets
podman network create --subnet, --gateway and --ip-range can now be specified multiple times to join the network to more than one subnet. This is very useful if you want to use a dual stack network and assign a fixed ipv4 and ipv6 subnet. The order of the options is important here, the first --gateway/--ip-range will be assigned to the first subnet and so on. Signed-off-by: Paul Holzinger <pholzing@redhat.com>
Diffstat (limited to 'pkg')
-rw-r--r--pkg/domain/entities/network.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/pkg/domain/entities/network.go b/pkg/domain/entities/network.go
index 79edc3227..a057640b3 100644
--- a/pkg/domain/entities/network.go
+++ b/pkg/domain/entities/network.go
@@ -43,12 +43,12 @@ type NetworkRmReport struct {
type NetworkCreateOptions struct {
DisableDNS bool
Driver string
- Gateway net.IP
+ Gateways []net.IP
Internal bool
Labels map[string]string
MacVLAN string
- Range net.IPNet
- Subnet net.IPNet
+ Ranges []string
+ Subnets []string
IPv6 bool
// Mapping of driver options and values.
Options map[string]string