From b87daf476569c74114f0b669fe20d3b942aab8ac Mon Sep 17 00:00:00 2001 From: abrown38 Date: Tue, 13 Aug 2024 21:39:15 +0100 Subject: [PATCH] also add gpo workbench ou --- .../win_domain_controller/files/OpenStackADBuildv7.5.2.ps1 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ansible/roles/win_domain_controller/files/OpenStackADBuildv7.5.2.ps1 b/ansible/roles/win_domain_controller/files/OpenStackADBuildv7.5.2.ps1 index 62af5c8..d3ae445 100644 --- a/ansible/roles/win_domain_controller/files/OpenStackADBuildv7.5.2.ps1 +++ b/ansible/roles/win_domain_controller/files/OpenStackADBuildv7.5.2.ps1 @@ -329,12 +329,14 @@ $DomainName = "$winProject.loc" # Create and link GPO New-GPO -Name $GpoName -New-GPLink -Name $GpoName -Target "DC=$($DomainName.Split('.')[0]),DC=$($DomainName.Split('.')[1])" # Configure GPO to disable Windows Firewall Set-GPRegistryValue -Name $GpoName -Key "HKLM\SOFTWARE\Policies\Microsoft\WindowsFirewall\DomainProfile" -ValueName "EnableFirewall" -Type DWord -Value 0 Set-GPRegistryValue -Name $GpoName -Key "HKLM\SOFTWARE\Policies\Microsoft\WindowsFirewall\PrivateProfile" -ValueName "EnableFirewall" -Type DWord -Value 0 Set-GPRegistryValue -Name $GpoName -Key "HKLM\SOFTWARE\Policies\Microsoft\WindowsFirewall\PublicProfile" -ValueName "EnableFirewall" -Type DWord -Value 0 + +New-GPLink -Name $GpoName -Target "DC=$($DomainName.Split('.')[0]),DC=$($DomainName.Split('.')[1])" +New-GPLink -Name $GpoName -Target $workbenchOU ############# Workaround - Adam ############# #Import-Module -Name NetSecurity