summaryrefslogtreecommitdiff
path: root/src/op_mode
diff options
context:
space:
mode:
authorNataliia Solomko <natalirs1985@gmail.com>2026-02-27 21:22:15 +0200
committerNataliia Solomko <natalirs1985@gmail.com>2026-03-03 17:52:40 +0200
commitc90512f68dbabe6f005c259f6e787abe527fe975 (patch)
tree86166dcd8b9ddf17611a0b6f2142d1130604e981 /src/op_mode
parentd47be4a8e2119e2be0be5fe9d7c29d7d8eaf24d9 (diff)
downloadvyos-1x-c90512f68dbabe6f005c259f6e787abe527fe975.tar.gz
vyos-1x-c90512f68dbabe6f005c259f6e787abe527fe975.zip
vpp: T8327: Migrate bridge interface to 'interfaces vpp bridge'
Diffstat (limited to 'src/op_mode')
-rwxr-xr-xsrc/op_mode/vpp.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/op_mode/vpp.py b/src/op_mode/vpp.py
index 868f780ae..54b46cf68 100755
--- a/src/op_mode/vpp.py
+++ b/src/op_mode/vpp.py
@@ -277,17 +277,17 @@ class VPPShow:
if ifname is None:
return None
- if not ifname.startswith('br') and not ifname[2:].isdigit():
+ if not ifname.startswith('vppbr') and not ifname[5:].isdigit():
raise vyos.opmode.IncorrectValue(
- f'"{ifname}" is not a valid bridge interface name (expected brN)'
+ f'"{ifname}" is not a valid bridge interface name (expected vppbrN)'
)
- if not self.config.exists(['vpp', 'interfaces', 'bridge', ifname]):
+ if not self.config.exists(['interfaces', 'vpp', 'bridge', ifname]):
raise vyos.opmode.IncorrectValue(
f'Bridge interface {ifname} does not exist'
)
- return int(ifname[2:])
+ return int(ifname[5:])
def _get_bridge_domain_raw(
self, bd_id: typing.Optional[int] = None
@@ -401,12 +401,12 @@ def show_lacp_details(raw: bool, ifname: typing.Optional[str]):
# -----------------------------
# Bridge op-mode entries
# -----------------------------
-@_verify('vpp interfaces bridge')
+@_verify('interfaces vpp bridge')
def show_bridge(raw: bool, ifname: typing.Optional[str] = None):
return VPPShow().bridge_domain(raw, ifname)
-@_verify('vpp interfaces bridge')
+@_verify('interfaces vpp bridge')
def show_bridge_details(raw: bool, ifname: typing.Optional[str] = None):
return VPPShow().bridge_domain_details(raw, ifname)