1
0
mirror of https://github.com/eworm-de/routeros-scripts.git synced 2024-05-11 05:55:19 +00:00

global-functions: $DownloadPackage: check status of certificate download

This commit is contained in:
Christian Hesse
2020-04-03 14:43:36 +02:00
parent 151630b674
commit abb97601ce

View File

@@ -212,6 +212,7 @@
:global CertificateAvailable;
:global CleanFilePath;
:global LogPrintExit;
:global WaitForFile;
:if ([ :len $PkgName ] = 0) do={ return false; }
@@ -224,7 +225,9 @@
}
:local PkgDest [ $CleanFilePath ($PkgDir . "/" . $PkgFile) ];
$CertificateAvailable "Let's Encrypt Authority X3";
:if ([ $CertificateAvailable "Let's Encrypt Authority X3" ] = false) do={
$LogPrintExit error ("Downloading required certificate failed.") true;
}
:local Retry 3;
:while ($Retry > 0) do={