Add AD Users in a specific department to an AD Group

I received a question, the other day, if there is a way to automate for AD users, in a specific department, to be added to an AD group.  The following script answers the question and can be put into Orchestrator or as a Task Scheduler for automate that.

The script will find all users that have their AD attribute department set to “IT” and put them in the AD group “IT Admins”.

To be able to use the script you need to have the AD PowerShell module installed.

 

No comments yet.

Leave a Reply