diff options
author | Andreas <vyos-git@justsecure.de> | 2021-12-29 18:02:06 +0100 |
---|---|---|
committer | Christian Poessinger <christian@poessinger.com> | 2022-02-20 22:05:16 +0100 |
commit | 0ecddff7cffa8900d351d5c15e32420f9d780c0b (patch) | |
tree | d27abc7030a0d0c9d774e8937d757cea544abfdb /python/vyos | |
parent | 529af7898d062b42ac33e15bfdc62c14184e098f (diff) | |
download | vyos-1x-0ecddff7cffa8900d351d5c15e32420f9d780c0b.tar.gz vyos-1x-0ecddff7cffa8900d351d5c15e32420f9d780c0b.zip |
vxlan: T4120: add ability to set multiple remotes (PR #1127)
VXLAN does support using multiple remotes but VyOS does not. Add the ability
to set multiple remotes and add their flood lists using "bridge" command.
Diffstat (limited to 'python/vyos')
-rw-r--r-- | python/vyos/ifconfig/vxlan.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/python/vyos/ifconfig/vxlan.py b/python/vyos/ifconfig/vxlan.py index 0c5282db4..87b5e40b8 100644 --- a/python/vyos/ifconfig/vxlan.py +++ b/python/vyos/ifconfig/vxlan.py @@ -82,3 +82,10 @@ class VXLANIf(Interface): self._cmd(cmd.format(**self.config)) # interface is always A/D down. It needs to be enabled explicitly self.set_admin_state('down') + + other_remotes = self.config.get('other_remotes') + if other_remotes: + for rem in other_remotes: + self.config['rem'] = rem + cmd2 = 'bridge fdb append to 00:00:00:00:00:00 dst {rem} port {port} dev {ifname}' + self._cmd(cmd2.format(**self.config)) |