From 544e73ff26bb0b9d282159e4a734ad531213d816 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Fri, 10 Dec 2021 21:15:18 +0100 Subject: vxlan: T3700: can not specify both "external" and "VNI" --- src/conf_mode/interfaces-vxlan.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/conf_mode') diff --git a/src/conf_mode/interfaces-vxlan.py b/src/conf_mode/interfaces-vxlan.py index b197d08a6..95d982f38 100755 --- a/src/conf_mode/interfaces-vxlan.py +++ b/src/conf_mode/interfaces-vxlan.py @@ -81,6 +81,9 @@ def verify(vxlan): raise ConfigError( 'Must either configure VXLAN "vni" or use "external" CLI option!') + if {'external', 'vni'} <= set(vxlan): + raise ConfigError('Can not specify both "external" and "VNI"!') + if {'external', 'other_tunnels'} <= set(vxlan): other_tunnels = ', '.join(vxlan['other_tunnels']) raise ConfigError(f'Only one VXLAN tunnel is supported when "external" '\ -- cgit v1.2.3