Windows 10 - Post Installation Tasks won't run
04/03/2017 3162 views
I have two post installation Tasks for Windows 10.
1) Windows 10 Activation
2) Compute Rename, Computer Description Change and Add to Domain
First of all, the scripts won't run except If I elevate them to run as admin via a bridge script and again in order for the Powershell script to run there is a pop up that I need to click yes to allow the Powershell script to run.
For Windows 10 Activation we are using MAK Keys. In order to Activate the copy of Windows, I am using slmgr.vbs -IPK command and slmgr.vbs -ATO command and although the ato command states that the Windows copy has been activated it when you login windows are not activated.
For the joining domain part although the join to domain part succeeds it doesn't rename the computer and instead it creates a randomly generated name.
In order to join it to the domain, I am using the command below
Add-Computer -DomainName XXXXXXXXX -NewName $NewName -Options JoinWithNewName,AccountCreate -Credential $AdminAccount
So eventually I would like for the scripts to run without any pop ups and failures. I thought maybe disabling UAC would help but on my tests even as an admin trying to run these scripts fail and they need elevation, which I don't really understand why.