So, I have a script that is running on FirstLogonCommands after a sysprep. This script joins the computer to the domain and adds a couple of AD groups to the local administrators list. This is great, however, adding the "FirstLogonCommands" appears to have taken precedence over the OOBE prompt that lets me type in a unique computer name. That being said--does anyone know of a way to make the OOBE prompt run BEFORE the firstlogoncommands executes this batch file? If not, is there a line of code I can add to the batch file that will prompt me to enter a computer name as local administrator before it starts the process of joining the domain?
Here's my existing script:
Set /P UserD=Enter a "Domain Admin" user name:
NetDom Join %COMPUTERNAME% /Domain:COMPANY.COM /UserD:%UserD% /PasswordD:* /OU:ou=WORKSTATIONS,dc=COMPANY,dc=COM
Net LocalGroup Administrators "DOMAIN\SECURITYGROUP" /add