АГ
Size: a a a
АГ
L
D
D
D
D
SJ
АГ
D
D
АГ
K
:local noipuser "user@email.com";
:local noippass "password";
:local noiphost "host";
/tool fetch url="http://myip.dnsomatic.com/" mode=http dst-path=mypublicip.txt
:local currentIP [/file get mypublicip.txt contents]
:local ddnsIP [resolve $noiphost server=8.8.8.8];
:if ($currentIP != $ddnsIP) do={
:log info "Current IP and DDNS IP mismatch, updating (current $currentIP, ddns $ddnsIP)";
:local url "http://dynupdate.no-ip.com/nic/update\3Fmyip=$currentIP";
:local url2 ("$url" . "&hostname=$noiphost");
/tool fetch mode=http url="$url2" user=$noipuser password=$noippass keep-result=no;
} else={:log info "IP addresses match, no update needed";}
D
D
АМ
АГ
АМ
АГ
АМ
АГ