With this scheduled task you can install all windows updates without user intervention. The reboot is automatic until all updates are installed.
Download the three files on the following gist. The files must be copied in the folder C:\WUA:
After copying these three files open the task scheduler and import the WUA_SearchDownloadInstall.xml file. At the next reboot the task will start the update process and will reboot the pc many times until all updates are installed.
IMPORTANT: Remember to disable or delete the task when finished.