Disassembler0 / Win10-Initial-Setup-Script

PowerShell script for automation of routine tasks done after fresh installations of Windows 10 / Server 2016 / Server 2019
MIT License
4.7k stars 1.08k forks source link

Add the option to switch automatic updates to manual for Non-Active Directory environments #203

Closed pablospizzamiglio closed 5 years ago

pablospizzamiglio commented 5 years ago

Hello,

I've added the option to change the Windows Update registry key "AUOptions" for environments that aren't memebers of an Active Directory and aren't being controlled by Group Policies.

AUOptions value will be switched to 2 (Notify before download) if the DisableUpdateAutoDownload function is used as part of the presets.

The revert function will simply delete the key thus restoring HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU to its original state for this particular key.

Link to the official documentation https://docs.microsoft.com/de-de/security-updates/windowsupdateservices/18127499