forked from dsccommunity/ActiveDirectoryDsc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
3-ADGroup_NewGroupMultidomainMembers_Config.ps1
40 lines (37 loc) · 1.21 KB
/
3-ADGroup_NewGroupMultidomainMembers_Config.ps1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<#PSScriptInfo
.VERSION 1.0.1
.GUID 24e89cf1-5696-499e-9e3c-e44df3a9948f
.AUTHOR DSC Community
.COMPANYNAME DSC Community
.COPYRIGHT DSC Community contributors. All rights reserved.
.TAGS DSCConfiguration
.LICENSEURI https://github.com/dsccommunity/ActiveDirectoryDsc/blob/main/LICENSE
.PROJECTURI https://github.com/dsccommunity/ActiveDirectoryDsc
.ICONURI https://dsccommunity.org/images/DSC_Logo_300p.png
.RELEASENOTES
Updated author, copyright notice, and URLs.
#>
#Requires -Module ActiveDirectoryDsc
<#
.DESCRIPTION
This configuration will create a new domain-local group in contoso with
three members in different domains.
#>
Configuration ADGroup_NewGroupMultiDomainMembers_Config
{
Import-DscResource -ModuleName ActiveDirectoryDsc
node localhost
{
ADGroup 'dl1'
{
GroupName = 'DL_APP_1'
GroupScope = 'DomainLocal'
MembershipAttribute = 'DistinguishedName'
Members = @(
'CN=john,OU=Accounts,DC=contoso,DC=com'
'CN=jim,OU=Accounts,DC=subdomain,DC=contoso,DC=com'
'CN=sally,OU=Accounts,DC=anothersub,DC=contoso,DC=com'
)
}
}
}