Quantcast
Channel: The Official Scripting Guys Forum! forum
Viewing all articles
Browse latest Browse all 15028

specify a user to join pre-created computer account to domain

$
0
0

I have a working script that creates multiple computer accounts in an AD domain.

 $OU='OU=compOU,DC=domain,DC=local'

Import-Csv c:\NewComputers.csv | ForEach-Object { New-ADComputer -name $_.computeraccount -samaccountname $_.samaccountname -Path $OU -Enabled $True }

 I would like to build on this script by specifying a certain user account to be able to join each new computer to the domain from the computer side.  Not sure how to proceed. 

Thx


Viewing all articles
Browse latest Browse all 15028

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>