mirror of
https://github.com/eworm-de/routeros-scripts.git
synced 2026-07-20 16:21:36 +00:00
global-functions: $ScriptInstallUpdate: allow to force checksums
This is a follow-up on aa14c26488 and
allows to use checksums for custom hosting.
This commit is contained in:
parent
93e593a891
commit
532fb45602
1 changed files with 3 additions and 1 deletions
|
|
@ -1282,6 +1282,7 @@
|
||||||
:global IDonate;
|
:global IDonate;
|
||||||
:global NoNewsAndChangesNotification;
|
:global NoNewsAndChangesNotification;
|
||||||
:global ScriptUpdatesBaseUrl;
|
:global ScriptUpdatesBaseUrl;
|
||||||
|
:global ScriptUpdatesCheckSums;
|
||||||
:global ScriptUpdatesCRLF;
|
:global ScriptUpdatesCRLF;
|
||||||
:global ScriptUpdatesUrlSuffix;
|
:global ScriptUpdatesUrlSuffix;
|
||||||
|
|
||||||
|
|
@ -1318,7 +1319,8 @@
|
||||||
:local DeviceMode [ /system/device-mode/get ];
|
:local DeviceMode [ /system/device-mode/get ];
|
||||||
|
|
||||||
:local CheckSums ({});
|
:local CheckSums ({});
|
||||||
:if ([ :pick $ScriptUpdatesBaseUrl 0 21 ] = "https://rsc.eworm.de/") do={
|
:if ([ :pick $ScriptUpdatesBaseUrl 0 21 ] = "https://rsc.eworm.de/" || \
|
||||||
|
$ScriptUpdatesCheckSums = true) do={
|
||||||
:onerror Err {
|
:onerror Err {
|
||||||
:local Url ($ScriptUpdatesBaseUrl . "checksums.json" . $ScriptUpdatesUrlSuffix);
|
:local Url ($ScriptUpdatesBaseUrl . "checksums.json" . $ScriptUpdatesUrlSuffix);
|
||||||
$LogPrint debug $0 ("Fetching checksums from url: " . $Url);
|
$LogPrint debug $0 ("Fetching checksums from url: " . $Url);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue