summaryrefslogtreecommitdiff
path: root/data/templates/accel-ppp/chap-secrets.config_dict.j2
diff options
context:
space:
mode:
Diffstat (limited to 'data/templates/accel-ppp/chap-secrets.config_dict.j2')
-rw-r--r--data/templates/accel-ppp/chap-secrets.config_dict.j210
1 files changed, 10 insertions, 0 deletions
diff --git a/data/templates/accel-ppp/chap-secrets.config_dict.j2 b/data/templates/accel-ppp/chap-secrets.config_dict.j2
new file mode 100644
index 000000000..51e66d57c
--- /dev/null
+++ b/data/templates/accel-ppp/chap-secrets.config_dict.j2
@@ -0,0 +1,10 @@
+# username server password acceptable local IP addresses shaper
+{% if authentication.local_users.username is vyos_defined %}
+{% for user, user_config in authentication.local_users.username.items() if user_config.disabled is not vyos_defined %}
+{% if user_config.rate_limit is vyos_defined %}
+{{ "%-12s" | format(user) }} * {{ "%-16s" | format(user_config.password) }} {{ "%-16s" | format(user_config.static_ip) }} {{ user_config.rate_limit.download }}/{{ user_config.rate_limit.upload }}
+{% else %}
+{{ "%-12s" | format(user) }} * {{ "%-16s" | format(user_config.password) }} {{ "%-16s" | format(user_config.static_ip) }}
+{% endif %}
+{% endfor %}
+{% endif %}