summaryrefslogtreecommitdiff
path: root/data/templates/accel-ppp/pppoe.config.tmpl
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2023-08-31 17:35:01 +0200
committerGitHub <noreply@github.com>2023-08-31 17:35:01 +0200
commitcfb75337c242301a2f4bbeeb9e8106c01fee235c (patch)
tree9395f103758bd6357193dc974da5b341be01262a /data/templates/accel-ppp/pppoe.config.tmpl
parent8e9709002abf2ba5784153025511e296724ff128 (diff)
parent0bf8c55386f0c3d684089c8bdc93e762fe7f7122 (diff)
downloadvyos-1x-cfb75337c242301a2f4bbeeb9e8106c01fee235c.tar.gz
vyos-1x-cfb75337c242301a2f4bbeeb9e8106c01fee235c.zip
Merge pull request #2168 from sever-sever/T3546
T3546: PPPoE-server add extended scripts for RADIUS attributes
Diffstat (limited to 'data/templates/accel-ppp/pppoe.config.tmpl')
-rw-r--r--data/templates/accel-ppp/pppoe.config.tmpl14
1 files changed, 14 insertions, 0 deletions
diff --git a/data/templates/accel-ppp/pppoe.config.tmpl b/data/templates/accel-ppp/pppoe.config.tmpl
index b37004f5b..3e5c64eb8 100644
--- a/data/templates/accel-ppp/pppoe.config.tmpl
+++ b/data/templates/accel-ppp/pppoe.config.tmpl
@@ -17,6 +17,10 @@ net-snmp
{% if limits is defined %}
connlimit
{% endif %}
+{% if extended_scripts is defined %}
+sigchld
+pppd_compat
+{% endif %}
[core]
thread-count={{ thread_count }}
@@ -167,5 +171,15 @@ timeout={{ limits.timeout }}
{# Common RADIUS shaper configuration #}
{% include 'accel-ppp/config_shaper_radius.j2' %}
+{% if extended_scripts is defined %}
+[pppd-compat]
+verbose=1
+radattr-prefix=/run/accel-pppd/radattr
+{% set script_name = {'on_up': 'ip-up', 'on_down': 'ip-down', 'on_change':'ip-change', 'on_pre_up':'ip-pre-up'} %}
+{% for script in extended_scripts %}
+{{ script_name[script] }}={{ extended_scripts[script] }}
+{% endfor %}
+{% endif %}
+
[cli]
tcp=127.0.0.1:2001