File tree 1 file changed +10
-1
lines changed
1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -64,6 +64,15 @@ If (-not $isAdmin) {
64
64
$LabConfig.DHCPscope = " 10.0.0.0"
65
65
}
66
66
67
+ if (! $LabConfig.DHCPscopeActive ){
68
+ $DHCPScopeState = ' Active'
69
+ }
70
+ elseif ($LabConfig.DHCPscopeActive -eq $false ){
71
+ $DHCPScopeState = ' Inactive'
72
+ }
73
+ else {
74
+ $DHCPScopeState = ' Active'
75
+ }
67
76
68
77
# create some built-in variables
69
78
$DN = $null
@@ -525,7 +534,7 @@ if (-not $DCFilesExists){
525
534
# region create DC if it does not exist
526
535
if (-not $DCFilesExists ) {
527
536
if (-not $LabConfig.NoDehydrateDC ){
528
- Hydrate- DC - DCName $DCName - VhdPath $vhdpath - VmPath $VmPath - SwitchName $Switchname - TimeZone $TimeZone - DhcpScope $LabConfig.DHCPscope - AdminPassword $AdminPassword
537
+ Hydrate- DC - DCName $DCName - VhdPath $vhdpath - VmPath $VmPath - SwitchName $Switchname - TimeZone $TimeZone - DhcpScope $LabConfig.DHCPscope - DHCPScopeState $DHCPScopeState - AdminPassword $AdminPassword
529
538
$DC = Get-VM - Name $DCName
530
539
if ($DC -eq $null ){
531
540
WriteErrorAndExit " DC was not created successfully Press any key to continue ..."
You can’t perform that action at this time.
0 commit comments