Update check-routeros-update.rsc

Neighbour version can have a date suffix. This changes to match only on the benginning.
This commit is contained in:
Ben Harris 2023-07-13 09:38:20 +08:00 committed by GitHub
parent 313e026229
commit 7849642c0b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -80,7 +80,7 @@ $LogPrintExit2 debug $0 ("Checking for updates...") false;
} }
:if ($SafeUpdateNeighbor = true && [ :len [ /ip/neighbor/find where \ :if ($SafeUpdateNeighbor = true && [ :len [ /ip/neighbor/find where \
version=($Update->"latest-version" . " (" . $Update->"channel" . ")") ] ] > 0) do={ version~($Update->"latest-version" . " \\(" . $Update->"channel" . "\\).*") ] ] > 0) do={
$LogPrintExit2 info $0 ("Seen a neighbor running version " . $Update->"latest-version" . ", updating...") false; $LogPrintExit2 info $0 ("Seen a neighbor running version " . $Update->"latest-version" . ", updating...") false;
$SendNotification2 ({ origin=$0; \ $SendNotification2 ({ origin=$0; \
subject=([ $SymbolForNotification "sparkles" ] . "RouterOS update: " . $Update->"latest-version"); \ subject=([ $SymbolForNotification "sparkles" ] . "RouterOS update: " . $Update->"latest-version"); \