Skip to content

Instantly share code, notes, and snippets.

@jonathanmedd
Created October 23, 2019 16:19
Show Gist options
  • Save jonathanmedd/93a70d1ead0998c99a139ab070bf2db4 to your computer and use it in GitHub Desktop.
Save jonathanmedd/93a70d1ead0998c99a139ab070bf2db4 to your computer and use it in GitHub Desktop.
_6_invoke-dsc.yml
---
- hosts: all
tasks:
- name: Powershell | Install Required Powershell Modules
win_psmodule:
name: xActiveDirectory
state: present
- name: Create Test Account
win_dsc:
resource_name: xADUser
DomainName: springfield.local
UserName: "test_user"
Password_password: "P@ssword!"
Password_username: "dummy"
Ensure: present
Path: "OU=Users,OU=HQ,DC=springfield,DC=local"
DisplayName: "Test User"
GivenName: "Test"
Surname: "User"
UserPrincipalName: "test_user@springfield.local"
Enabled: true
PasswordNeverExpires: true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment