diff options
Diffstat (limited to 'python/vyos')
-rw-r--r-- | python/vyos/configdict.py | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/python/vyos/configdict.py b/python/vyos/configdict.py index ead7e8637..824ca1f71 100644 --- a/python/vyos/configdict.py +++ b/python/vyos/configdict.py @@ -235,8 +235,16 @@ def intf_to_dict(conf, default): # DHCPv6 prefix delegation (RFC3633) current_level = conf.get_level() if conf.exists(['dhcpv6-options', 'prefix-delegation']): - for interface in conf.list_nodes(['dhcpv6-options', 'prefix-delegation', 'interface']): - conf.set_level(current_level + ['dhcpv6-options', 'prefix-delegation', 'interface', interface]) + dhcpv6_pd_path = current_level + ['dhcpv6-options', 'prefix-delegation'] + conf.set_level(dhcpv6_pd_path) + + # retriebe DHCPv6-PD prefix helper length as some ISPs only hand out a + # /64 by default (https://phabricator.vyos.net/T2506) + if conf.exists(['length']): + intf['dhcpv6_pd_length'] = conf.return_value(['length']) + + for interface in conf.list_nodes(['interface']): + conf.set_level(current_level + ['interface', interface]) pd = { 'ifname': interface, 'sla_id': '', |