mirror of
https://github.com/eworm-de/routeros-scripts
synced 2024-05-14 08:04:19 +00:00
ppp-on-up: use 'provides' to find ppp-on-up scripts
This commit is contained in:
parent
96a92bb30c
commit
aad2e062e5
13
ppp-on-up
13
ppp-on-up
|
@ -23,13 +23,8 @@
|
||||||
|
|
||||||
/ ipv6 dhcp-client release [ find where interface=$IntName !disabled ];
|
/ ipv6 dhcp-client release [ find where interface=$IntName !disabled ];
|
||||||
|
|
||||||
:local Scripts {
|
:foreach Script in=[ / system script find where source~("\n# provides: ppp-on-up\n") ] do={
|
||||||
"update-tunnelbroker"
|
:local ScriptName [ / system script get $Script name ];
|
||||||
}
|
:log debug ("Running script from ppp-on-up: " . $ScriptName);
|
||||||
|
/ system script run $Script;
|
||||||
:foreach Script in=$Scripts do={
|
|
||||||
:if ([ :len [ / system script find where name=$Script ] ] > 0) do={
|
|
||||||
:log debug ("Running script from ppp-on-up: " . $Script);
|
|
||||||
/ system script run $Script;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,6 +4,8 @@
|
||||||
# Michael Gisbers <michael@gisbers.de>
|
# Michael Gisbers <michael@gisbers.de>
|
||||||
# https://git.eworm.de/cgit/routeros-scripts/about/COPYING.md
|
# https://git.eworm.de/cgit/routeros-scripts/about/COPYING.md
|
||||||
#
|
#
|
||||||
|
# provides: ppp-on-up
|
||||||
|
#
|
||||||
# update local address of tunnelbroker interface
|
# update local address of tunnelbroker interface
|
||||||
# https://git.eworm.de/cgit/routeros-scripts/about/doc/update-tunnelbroker.md
|
# https://git.eworm.de/cgit/routeros-scripts/about/doc/update-tunnelbroker.md
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue