summaryrefslogtreecommitdiff
path: root/python/vyos/configverify.py
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2021-02-27 21:49:00 +0100
committerChristian Poessinger <christian@poessinger.com>2021-02-28 00:54:37 +0100
commit857294427afba3259e683f2360c735f0f4be32b6 (patch)
tree0f9a3af7320ce87a62eaaef62d89a1f6983015b4 /python/vyos/configverify.py
parent582b718221c67ddb71e39fbad0a72241761304a9 (diff)
downloadvyos-1x-857294427afba3259e683f2360c735f0f4be32b6.tar.gz
vyos-1x-857294427afba3259e683f2360c735f0f4be32b6.zip
tunnel: T3366: rename remote-ip to remote
Streamline the CLI configuration where we try to use remote on other interfaces like vxlan, geneve.
Diffstat (limited to 'python/vyos/configverify.py')
-rw-r--r--python/vyos/configverify.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/python/vyos/configverify.py b/python/vyos/configverify.py
index c901ccbc5..db3e7cc57 100644
--- a/python/vyos/configverify.py
+++ b/python/vyos/configverify.py
@@ -103,8 +103,8 @@ def verify_tunnel(config):
if 'source_address' not in config and 'dhcp_interface' not in config:
raise ConfigError('source-address is mandatory for tunnel')
- if 'remote_ip' not in config and config['encapsulation'] != 'gre':
- raise ConfigError('remote-ip is mandatory for tunnel')
+ if 'remote' not in config and config['encapsulation'] != 'gre':
+ raise ConfigError('remote ip address is mandatory for tunnel')
if {'source_address', 'dhcp_interface'} <= set(config):
raise ConfigError('Can not use both source-address and dhcp-interface')
@@ -114,15 +114,15 @@ def verify_tunnel(config):
if 'source_address' in config and not is_ipv6(config['source_address']):
raise ConfigError(f'{error_ipv6} source-address')
- if 'remote_ip' in config and not is_ipv6(config['remote_ip']):
- raise ConfigError(f'{error_ipv6} remote-ip')
+ if 'remote' in config and not is_ipv6(config['remote']):
+ raise ConfigError(f'{error_ipv6} remote')
else:
error_ipv4 = 'Encapsulation mode requires IPv4'
if 'source_address' in config and not is_ipv4(config['source_address']):
raise ConfigError(f'{error_ipv4} source-address')
- if 'remote_ip' in config and not is_ipv4(config['remote_ip']):
- raise ConfigError(f'{error_ipv4} remote-ip')
+ if 'remote' in config and not is_ipv4(config['remote']):
+ raise ConfigError(f'{error_ipv4} remote address')
if config['encapsulation'] in ['sit', 'gretap']:
if 'source_interface' in config: