From d95806ea2f2f91546c815ffaeb8ae3171a9d7fe4 Mon Sep 17 00:00:00 2001 From: William Lam Date: Tue, 19 Mar 2019 10:31:20 -0700 Subject: [PATCH] Fix CGW/MGW scope --- Modules/VMware.VMC.NSXT/VMware.VMC.NSXT.psm1 | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Modules/VMware.VMC.NSXT/VMware.VMC.NSXT.psm1 b/Modules/VMware.VMC.NSXT/VMware.VMC.NSXT.psm1 index fcfbe3c..d29abbc 100644 --- a/Modules/VMware.VMC.NSXT/VMware.VMC.NSXT.psm1 +++ b/Modules/VMware.VMC.NSXT/VMware.VMC.NSXT.psm1 @@ -525,7 +525,11 @@ Function New-NSXTFirewall { $scopeLabels = @() if(!$InfraScope) { - $scopeLabels = @("/infra/labels/$($GatewayType.toLower())-all") + if($GatewayType.toLower() -eq "cgw") { + $scopeLabels = @("/infra/labels/$($GatewayType.toLower())-all") + } else { + $scopeLabels = @("/infra/labels/$($GatewayType.toLower())") + } } else { foreach ($infraScopeName in $InfraScope) { $scope = Get-NSXTInfraScope -Name $infraScopeName