I added a scheduler item for this.
Triggered on startup. Checks if there's a newer version available and updates automagically.:
/system scheduler
add name=UpgradeFirmware on-event="if ([/system routerboard get current-firmware] < [/system routerboard get upgrade-firmware]) do={\r\
\n/system routerboard upgrade\r\
\n:delay 1\r\
\n/system reboot\r\
\n}\r\
\n" policy=ftp,reboot,read,write,policy,test,password,sniff,sensitive start-time=startup
To push this scheduler into each CAP, create an address list with all the IP addresses of your CAPs, save the code above in a file named scheduler.rsc and then add this to your scripts repository and run it once:
/system script
add name=addschedulerupdate policy=ftp,read,write,policy,test,winbox,password,sniff,sensitive,api source="
:foreach i in=[/ip firewall address-list find list=accesspoints] do={
[/tool fetch address=[/ip firewall address-list get $i address] mode=ftp user=login password=password src-path=/scheduler.rsc dst-path=scheduler.auto.rsc upload=yes];
}
-Chris