gbudny93.RouterOS_Useful_Sc.../RouterOS_All_Software_Download.rsc

25 lines
912 B
Text
Raw Permalink Normal View History

2020-04-19 17:57:02 +02:00
# RouterOS Fucntion
# Copyright (c) Grzegorz Budny
2020-07-03 10:07:33 +02:00
# Version 1.1
# Last update: 2020-07-03 10:07:02
2020-04-19 17:57:02 +02:00
# Automated download of all latest RouterOS standard packages.
# Tool recommended to CAPsMAN and DUDE servers
:global AutoSoftwareDownload do={
/system package update check-for-updates;
:local packageLatest [/system package update get latest-version];
:local packages {"mipsbe"; "smips"; "tile"; "powerpc"; "arm"; "x86"; "mmips"};
:foreach package in=$packages do={
/tool fetch http-method=get mode=https url=("https://download.mikrotik.com/routeros/".$packageLatest."/routeros-".("$package")."-".$packageLatest.".npk") dst-path=($destinationPath."/routeros-".("$package")."-".$packageLatest.".npk");
2020-07-03 10:07:33 +02:00
:log info ("...:::Downloading "."/routeros-".("$package")."-".$packageLatest.".npk");
2020-04-19 17:57:02 +02:00
}
}
#Example:
#$AutoSoftwareDownload destinationPath=destination_path