1
0
mirror of https://github.com/CumulusNetworks/ifupdown2.git synced 2024-05-06 15:54:50 +00:00

lib: iproute2: re-add missing bridge_vlan_add_vid_list method

Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
This commit is contained in:
Julien Fortin
2020-06-10 16:25:54 +02:00
parent 5f6de69fd3
commit 0e159829a6

View File

@@ -635,6 +635,13 @@ class IPRoute2(Cache, Requirements):
if "exists" not in str(e).lower():
self.logger.error(e)
@staticmethod
def bridge_vlan_add_vid_list(ifname, vids):
for v in vids:
utils.exec_command(
"%s vlan add vid %s dev %s" % (utils.bridge_cmd, v, ifname)
)
def bridge_vlan_add_vid_list_self(self, ifname, vids, is_bridge=True):
target = "self" if is_bridge else ""
for v in vids: