diff options
author | Christian Hesse <mail@eworm.de> | 2023-08-07 17:16:03 +0200 |
---|---|---|
committer | Christian Hesse <mail@eworm.de> | 2023-08-09 16:30:18 +0200 |
commit | d0ab951e3fbc2b4a82671e6844389068ef377549 (patch) | |
tree | 18eac818f2dc7ee3023a3c3cd5322a2220e9f9a8 /capsman-download-packages.template.rsc | |
parent | 3cab917a61cb84b08f99bd7b4a7b59b1a41024ac (diff) |
capsman-download-packages: download a default set for wifiwave2
Well, AX devices can be arm or arm64... So let's just download packages
'routeros' and 'wifiwave2' - crossing fingers... 🤞
Diffstat (limited to 'capsman-download-packages.template.rsc')
-rw-r--r-- | capsman-download-packages.template.rsc | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/capsman-download-packages.template.rsc b/capsman-download-packages.template.rsc index 4b52569..71bced0 100644 --- a/capsman-download-packages.template.rsc +++ b/capsman-download-packages.template.rsc @@ -81,8 +81,20 @@ $WaitFullyConnected; :set Updated true; } } - # NOT /interface/wifiwave2 # +# NOT /caps-man # +:if ([ :len [ /file/find where type=package name~("^" . $PackagePath) ] ] = 0) do={ + $LogPrintExit2 info $0 ("No packages available, downloading default set.") false; + :foreach Arch in={ "arm"; "arm64" } do={ + :foreach Package in={ "routeros"; "wifiwave2" } do={ + :if ([ $DownloadPackage $Package $InstalledVersion $Arch $PackagePath ] = true) do={ + :set Updated true; + } + } + } +} +# NOT /caps-man # + :if ($Updated = true) do={ :local Script ([ /system/script/find where source~"\n# provides: capsman-rolling-upgrade\n" ]->0); :if ([ :len $Script ] > 0) do={ |