summaryrefslogtreecommitdiff
path: root/src/conf_mode/interfaces-pppoe.py
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2020-08-23 01:16:47 +0200
committerChristian Poessinger <christian@poessinger.com>2020-08-23 01:16:47 +0200
commit1896eed01b0da55ed9a6740ad78673cfe207dc9d (patch)
tree35965564b3162732545b43ab25e4d2ae55e40743 /src/conf_mode/interfaces-pppoe.py
parent50a7544ad69cb7b631a499299f9ab32b2e8918a0 (diff)
parenta574a01ab5c02aeb90c6d099dce482c1bf8be096 (diff)
downloadvyos-1x-1896eed01b0da55ed9a6740ad78673cfe207dc9d.tar.gz
vyos-1x-1896eed01b0da55ed9a6740ad78673cfe207dc9d.zip
Merge branch 'dhcpv6-pd-cli-adjustment' of github.com:c-po/vyos-1x into current
* 'dhcpv6-pd-cli-adjustment' of github.com:c-po/vyos-1x: dhcpv6-pd: T2677: add support for rapid-commit option dhcpv6-pd: T2821: support dhcpv6-pd without "address dhcpv6" ifconfig: T2653: drop unused vyos.ifconfig.pppoe dhcpv6-pd: T2677: optimize CLI interface for PD configuration
Diffstat (limited to 'src/conf_mode/interfaces-pppoe.py')
-rwxr-xr-xsrc/conf_mode/interfaces-pppoe.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/conf_mode/interfaces-pppoe.py b/src/conf_mode/interfaces-pppoe.py
index 928113b49..901ea769c 100755
--- a/src/conf_mode/interfaces-pppoe.py
+++ b/src/conf_mode/interfaces-pppoe.py
@@ -15,7 +15,6 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
import os
-import jmespath
from sys import exit
from copy import deepcopy
@@ -104,8 +103,7 @@ def generate(pppoe):
render(script_pppoe_ipv6_up, 'pppoe/ipv6-up.script.tmpl',
pppoe, trim_blocks=True, permission=0o755)
- tmp = jmespath.search('dhcpv6_options.prefix_delegation.interface', pppoe)
- if tmp and len(tmp) > 0:
+ if 'dhcpv6_options' in pppoe and 'pd' in pppoe['dhcpv6_options']:
# ipv6.tmpl relies on ifname - this should be made consitent in the
# future better then double key-ing the same value
render(config_wide_dhcp6c, 'dhcp-client/ipv6.tmpl', pppoe, trim_blocks=True)