summaryrefslogtreecommitdiff
path: root/data/templates/l2tp
diff options
context:
space:
mode:
authorDmitriyEshenko <dmitriy.eshenko@vyos.io>2020-04-07 13:25:39 +0000
committerDmitriyEshenko <dmitriy.eshenko@vyos.io>2020-04-07 13:25:39 +0000
commit8cbbd2a9b32176172c05d22da5502b464b68e3a1 (patch)
tree401bada0ae7848f551c61d899d8ea9551ef939b6 /data/templates/l2tp
parent8cc6bd529c76c2958999dcc379c418d748181731 (diff)
downloadvyos-1x-8cbbd2a9b32176172c05d22da5502b464b68e3a1.tar.gz
vyos-1x-8cbbd2a9b32176172c05d22da5502b464b68e3a1.zip
l2tp: pptp: pppoe: T2237: Fix chap-secrets template format
Diffstat (limited to 'data/templates/l2tp')
-rw-r--r--data/templates/l2tp/chap-secrets.tmpl7
1 files changed, 3 insertions, 4 deletions
diff --git a/data/templates/l2tp/chap-secrets.tmpl b/data/templates/l2tp/chap-secrets.tmpl
index 323528b3c..0db295fdc 100644
--- a/data/templates/l2tp/chap-secrets.tmpl
+++ b/data/templates/l2tp/chap-secrets.tmpl
@@ -1,11 +1,10 @@
# username server password acceptable local IP addresses shaper
{% for user in authentication['local-users'] %}
{% if authentication['local-users'][user]['state'] == 'enabled' %}
-{% if (authentication['local-users'][user]['upload']) and (authentication['local-users'][user]['download']) %}
-{{user}}\t*\t{{authentication['local-users'][user]['passwd']}}\t{{authentication['local-users'][user]['ip']}}\t\
-{{authentication['local-users'][user]['download']}}/{{authentication['local-users'][user]['upload']}}
+{% if authentication['local-users'][user]['upload'] and authentication['local-users'][user]['download'] %}
+{{ "%-12s" | format(user) }} * {{ "%-16s" | format(authentication['local-users'][user]['passwd']) }} {{ "%-16s" | format(authentication['local-users'][user]['ip']) }} {{ authentication['local-users'][user]['download'] }} / {{ authentication['local-users'][user]['upload'] }}
{% else %}
-{{user}}\t*\t{{authentication['local-users'][user]['passwd']}}\t{{authentication['local-users'][user]['ip']}}
+{{ "%-12s" | format(user) }} * {{ "%-16s" | format(authentication['local-users'][user]['passwd']) }} {{ "%-16s" | format(authentication['local-users'][user]['ip']) }}
{% endif %}
{% endif %}
{% endfor %}