:local IFACE
:set IFACE INDIHOME
:local WANIP [/ip address get [find where interface=$IFACE] address];
:set WANIP [:pick $WANIP 0 ([:len $WANIP]-3) ];
:if ($WANIP ~"^10[.]") do={
:log warning "Private ip address found !!!"
/interface pppoe-client enable $IFACE
:delay 1
} else={
:if ($WANIP ~"^172.") do={
:log warning "Private ip address found !!!"
/interface pppoe-client enable $IFACE
:delay 1
} else={
:if ($WANIP ~"^192.") do={
:log warning "Private ip address found !!!"
/interface pppoe-client enable $IFACE
:delay 1
} else={
:log warning "Public IP - $WANIP - Found, OK ! No action required"
}
}
}
:delay 10
/ip cloud force-update
Thursday, May 7, 2020
Subscribe to:
Post Comments (Atom)
0 comments:
Post a Comment