summaryrefslogtreecommitdiff
path: root/python/vyos/ifconfig_vlan.py
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2020-05-25 21:11:43 +0200
committerChristian Poessinger <christian@poessinger.com>2020-05-26 17:09:33 +0200
commit7dddfa338800303335673df637a05d8aaaccdaa2 (patch)
treefc79b7308429223ea2b47be32c213c36d0b729ba /python/vyos/ifconfig_vlan.py
parentd5b58517f88358c686e6c8ea039a7a9a64d6c6ee (diff)
downloadvyos-1x-7dddfa338800303335673df637a05d8aaaccdaa2.tar.gz
vyos-1x-7dddfa338800303335673df637a05d8aaaccdaa2.zip
dhcpv6-pd: T2506: add option to request specific prefix length
Some ISPs (e.g. Comcast) only delegate a /64 by default. You have to explicitly "ask" for a bigger (e.g. /60) prefix. This commit adds a CLI node to request a specific prefix length in the range 32 - 64. dhcpv6-options { prefix-delegation { length 60 } }
Diffstat (limited to 'python/vyos/ifconfig_vlan.py')
-rw-r--r--python/vyos/ifconfig_vlan.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/python/vyos/ifconfig_vlan.py b/python/vyos/ifconfig_vlan.py
index ec4d1da42..53a77c651 100644
--- a/python/vyos/ifconfig_vlan.py
+++ b/python/vyos/ifconfig_vlan.py
@@ -87,6 +87,9 @@ def apply_vlan_config(vlan, config):
if config['dhcpv6_temporary']:
vlan.dhcp.v6.options['dhcpv6_temporary'] = True
+ if config['dhcpv6_pd_length']:
+ vlan.dhcp.v6.options['dhcpv6_pd_length'] = config['dhcpv6_pd_length']
+
if config['dhcpv6_pd_interfaces']:
vlan.dhcp.v6.options['dhcpv6_pd_interfaces'] = config['dhcpv6_pd_interfaces']