Initial commit
This commit is contained in:
12
Vagrant/scripts/configure-ou.ps1
Normal file
12
Vagrant/scripts/configure-ou.ps1
Normal file
@@ -0,0 +1,12 @@
|
||||
# Purpose: Sets up the Server and Workstations OUs
|
||||
Write-Host "Sleeping for 30 seconds, then creating Server and Workstation OUs"
|
||||
Start-Sleep 30
|
||||
Write-Host "Creating Servers OU"
|
||||
New-ADOrganizationalUnit -Name "Servers" -Server "dc.windomain.local"
|
||||
Write-Host "Creating Workstations OU"
|
||||
New-ADOrganizationalUnit -Name "Workstations" -Server "dc.windomain.local"
|
||||
|
||||
# Sysprep breaks auto-login. Let's restore it here:
|
||||
Set-ItemProperty "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" -Name AutoAdminLogon -Value 1
|
||||
Set-ItemProperty "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" -Name DefaultUserName -Value "vagrant"
|
||||
Set-ItemProperty "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" -Name DefaultPassword -Value "vagrant"
|
||||
Reference in New Issue
Block a user