Skip to content

Commit

Permalink
[AKS] support parameter OutboundType (Azure#21457)
Browse files Browse the repository at this point in the history
  • Loading branch information
YanaXu authored Apr 7, 2023
1 parent d4ea356 commit 901dc41
Show file tree
Hide file tree
Showing 6 changed files with 2,636 additions and 6 deletions.
7 changes: 7 additions & 0 deletions src/Aks/Aks.Test/ScenarioTests/KubernetesTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -205,5 +205,12 @@ public void TestEnableOidcIssuer()
{
TestRunner.RunTestScript("Test-EnableOidcIssuer");
}

[Fact]
[Trait(Category.AcceptanceType, Category.CheckIn)]
public void TestOutboundType()
{
TestRunner.RunTestScript("Test-OutboundType");
}
}
}
19 changes: 19 additions & 0 deletions src/Aks/Aks.Test/ScenarioTests/KubernetesTests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -1193,4 +1193,23 @@ function Test-EnableOidcIssuer {
finally {
Remove-AzResourceGroup -Name $resourceGroupName -Force
}
}

function Test-OutboundType {
# Setup
$resourceGroupName = Get-RandomResourceGroupName
$kubeClusterName = Get-RandomClusterName
$location = 'eastus'
$nodeVmSize = "Standard_D2_v2"

try {
New-AzResourceGroup -Name $resourceGroupName -Location $location

New-AzAksCluster -ResourceGroupName $resourceGroupName -Name $kubeClusterName -NodeVmSize $nodeVmSize -NodeCount 1 -OutboundType managedNATGateway
$cluster = Get-AzAksCluster -ResourceGroupName $resourceGroupName -Name $kubeClusterName
Assert-AreEqual 'managedNATGateway' $cluster.NetworkProfile.OutboundType
}
finally {
Remove-AzResourceGroup -Name $resourceGroupName -Force
}
}
Loading

0 comments on commit 901dc41

Please sign in to comment.