diff options
author | Christian Poessinger <christian@poessinger.com> | 2022-04-11 20:58:24 +0200 |
---|---|---|
committer | Christian Poessinger <christian@poessinger.com> | 2022-04-11 20:58:24 +0200 |
commit | 129e7f1d266186e40c715de9481daad25544df2f (patch) | |
tree | d0dfc4b1d3830b1247066cb45cab0882dbab835d /data/templates/pppoe/peer.tmpl | |
parent | b42ad4bf72915289ccb464942a94f35c34b12d37 (diff) | |
download | vyos-1x-129e7f1d266186e40c715de9481daad25544df2f.tar.gz vyos-1x-129e7f1d266186e40c715de9481daad25544df2f.zip |
pppoe: T4333: migrate to new vyos_defined Jinja2 test
Diffstat (limited to 'data/templates/pppoe/peer.tmpl')
-rw-r--r-- | data/templates/pppoe/peer.tmpl | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/data/templates/pppoe/peer.tmpl b/data/templates/pppoe/peer.tmpl index 928ed1238..d6d63debf 100644 --- a/data/templates/pppoe/peer.tmpl +++ b/data/templates/pppoe/peer.tmpl @@ -1,5 +1,5 @@ ### Autogenerated by interfaces-pppoe.py ### -{{ '# ' ~ description if description is defined else '' }} +{{ '# ' ~ description if description is vyos_defined else '' }} # Require peer to provide the local IP address if it is not # specified explicitly in the config file. @@ -35,10 +35,10 @@ noproxyarp maxfail 0 plugin rp-pppoe.so {{ source_interface }} -{% if access_concentrator is defined and access_concentrator is not none %} +{% if access_concentrator is vyos_defined %} rp_pppoe_ac '{{ access_concentrator }}' {% endif %} -{% if service_name is defined and service_name is not none %} +{% if service_name is vyos_defined %} rp_pppoe_service '{{ service_name }}' {% endif %} @@ -49,34 +49,34 @@ debug mtu {{ mtu }} mru {{ mtu }} -{% if authentication is defined %} -{{ 'user "' + authentication.user + '"' if authentication.user is defined }} -{{ 'password "' + authentication.password + '"' if authentication.password is defined }} +{% if authentication is vyos_defined %} +{{ 'user "' + authentication.user + '"' if authentication.user is vyos_defined }} +{{ 'password "' + authentication.password + '"' if authentication.password is vyos_defined }} {% endif %} -{{ "usepeerdns" if no_peer_dns is not defined }} +{{ "usepeerdns" if no_peer_dns is not vyos_defined }} -{% if ipv6 is defined %} -+ipv6 {{ 'ipv6cp-use-ipaddr' if ipv6.address is defined and ipv6.address.autoconf is defined }} +{% if ipv6 is vyos_defined %} ++ipv6 {{ 'ipv6cp-use-ipaddr' if ipv6.address.autoconf is vyos_defined }} {% else %} noipv6 {% endif %} -{% if connect_on_demand is defined %} +{% if connect_on_demand is vyos_defined %} demand # See T2249. PPP default route options should only be set when in on-demand # mode. As soon as we are not in on-demand mode the default-route handling is # passed to the ip-up.d/ip-down.s scripts which is required for VRF support. {% if 'auto' in default_route %} defaultroute -{{ 'defaultroute6' if ipv6 is defined }} +{{ 'defaultroute6' if ipv6 is vyos_defined }} {% elif 'force' in default_route %} defaultroute replacedefaultroute -{{ 'defaultroute6' if ipv6 is defined }} +{{ 'defaultroute6' if ipv6 is vyos_defined }} {% endif %} {% else %} nodefaultroute noreplacedefaultroute -{{ 'nodefaultroute6' if ipv6 is defined }} +{{ 'nodefaultroute6' if ipv6 is vyos_defined }} {% endif %} |