File tree Expand file tree Collapse file tree 4 files changed +40
-2
lines changed
Deploy-AD/DesiredSateConfig Expand file tree Collapse file tree 4 files changed +40
-2
lines changed Original file line number Diff line number Diff line change @@ -33,12 +33,31 @@ configuration ADD-DC1-Services {
3333 ConfigurationMode = ' ApplyOnly'
3434 RebootNodeIfNeeded = $true
3535 }
36+
37+ xScript DelayBeforeDNS
38+ {
39+ SetScript = {
40+ # Force a 30 second sleep
41+ Start-Sleep - seconds 30
42+ }
43+
44+ GetScript =
45+ {
46+ return @ { " Result" = " false" }
47+ }
48+
49+ TestScript =
50+ {
51+ return $false
52+ }
53+ }
3654
3755 # ***** Add DNS and AD Features *****
3856 WindowsFeature DNS
3957 {
40- Ensure = " Present"
41- Name = " DNS"
58+ Ensure = " Present"
59+ Name = " DNS"
60+ DependsOn = ' [xScript]DelayBeforeDNS'
4261 }
4362
4463 Script EnableDNSDiags
Original file line number Diff line number Diff line change @@ -33,11 +33,30 @@ configuration Join-Domain {
3333 RebootNodeIfNeeded = $true
3434 }
3535
36+ xScript DelayBeforeDNS
37+ {
38+ SetScript = {
39+ # Force a 30 second sleep
40+ Start-Sleep - seconds 30
41+ }
42+
43+ GetScript =
44+ {
45+ return @ { " Result" = " false" }
46+ }
47+
48+ TestScript =
49+ {
50+ return $false
51+ }
52+ }
53+
3654 DnsServerAddress SetDNS
3755 {
3856 Address = $DCIPAddress
3957 InterfaceAlias = $InterfaceAlias
4058 AddressFamily = ' IPv4'
59+ DependsOn = ' [xScript]DelayBeforeDNS'
4160 }
4261
4362 # ***** Join Domain *****
You can’t perform that action at this time.
0 commit comments