Skip to content

Commit 42a2066

Browse files
committed
Align QS with Public LB QS regarding zone usage
1 parent 3b9d7a0 commit 42a2066

File tree

1 file changed

+43
-17
lines changed

1 file changed

+43
-17
lines changed

articles/load-balancer/quickstart-load-balancer-standard-internal-powershell.md

Lines changed: 43 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ description: This quickstart shows how to create an internal load balancer using
55
author: mbender-ms
66
ms.service: load-balancer
77
ms.topic: quickstart
8-
ms.date: 03/24/2022
8+
ms.date: 09/02/2022
99
ms.author: mbender
1010
ms.custom: devx-track-azurepowershell, mode-api
1111
#Customer intent: I want to create a load balancer so that I can load balance internal traffic to VMs.
@@ -37,11 +37,46 @@ New-AzResourceGroup -Name 'CreateIntLBQS-rg' -Location 'eastus'
3737

3838
When you create an internal load balancer, a virtual network is configured as the network for the load balancer. Before you deploy VMs and test your load balancer, create the supporting virtual network resources.
3939

40-
Create a virtual network for the backend virtual machines
40+
- Create a public IP for the NAT gateway
4141

42-
Create a network security group to define inbound connections to your virtual network
42+
- Create a virtual network for the backend virtual machines
4343

44-
Create an Azure Bastion host to securely manage the virtual machines in the backend pool
44+
- Create a network security group to define inbound connections to your virtual network
45+
46+
- Create an Azure Bastion host to securely manage the virtual machines in the backend pool
47+
48+
## Create a public IP address
49+
50+
Use [New-AzPublicIpAddress](/powershell/module/az.network/new-azpublicipaddress) to create a public IP address for the NAT gateway.
51+
52+
```azurepowershell-interactive
53+
## Create public IP address for NAT gateway and place IP in variable ##
54+
$gwpublicip = @{
55+
Name = 'myNATgatewayIP'
56+
ResourceGroupName = 'CreatePubLBQS-rg'
57+
Location = 'eastus'
58+
Sku = 'Standard'
59+
AllocationMethod = 'static'
60+
Zone = 1,2,3
61+
}
62+
$gwpublicip = New-AzPublicIpAddress @gwpublicip
63+
```
64+
65+
To create a zonal public IP address in zone 1, use the following command:
66+
67+
```azurepowershell-interactive
68+
## Create a zonal public IP address for NAT gateway and place IP in variable ##
69+
$gwpublicip = @{
70+
Name = 'myNATgatewayIP'
71+
ResourceGroupName = 'CreatePubLBQS-rg'
72+
Location = 'eastus'
73+
Sku = 'Standard'
74+
AllocationMethod = 'static'
75+
Zone = 1
76+
}
77+
$gwpublicip = New-AzPublicIpAddress @gwpublicip
78+
79+
```
4580

4681
### Create virtual network, network security group, bastion host, and NAT gateway
4782

@@ -56,15 +91,6 @@ Create an Azure Bastion host to securely manage the virtual machines in the back
5691
* Use [New-AzVirtualNetworkSubnetConfig](/powershell/module/az.network/new-azvirtualnetworksubnetconfig) to associate the NAT gateway to the subnet of the virtual network
5792

5893
```azurepowershell-interactive
59-
## Create public IP address for NAT gateway ##
60-
$ip = @{
61-
Name = 'myNATgatewayIP'
62-
ResourceGroupName = 'CreatePubLBQS-rg'
63-
Location = 'eastus'
64-
Sku = 'Standard'
65-
AllocationMethod = 'Static'
66-
}
67-
$publicIP = New-AzPublicIpAddress @ip
6894
6995
## Create NAT gateway resource ##
7096
$nat = @{
@@ -73,7 +99,7 @@ $nat = @{
7399
IdleTimeoutInMinutes = '10'
74100
Sku = 'Standard'
75101
Location = 'eastus'
76-
PublicIpAddress = $publicIP
102+
PublicIpAddress = $gwpublicip
77103
}
78104
$natGateway = New-AzNatGateway @nat
79105
@@ -103,20 +129,20 @@ $net = @{
103129
$vnet = New-AzVirtualNetwork @net
104130
105131
## Create public IP address for bastion host. ##
106-
$ip = @{
132+
$bastionip = @{
107133
Name = 'myBastionIP'
108134
ResourceGroupName = 'CreateIntLBQS-rg'
109135
Location = 'eastus'
110136
Sku = 'Standard'
111137
AllocationMethod = 'Static'
112138
}
113-
$publicip = New-AzPublicIpAddress @ip
139+
$bastionip = New-AzPublicIpAddress @bastionip
114140
115141
## Create bastion host ##
116142
$bastion = @{
117143
ResourceGroupName = 'CreateIntLBQS-rg'
118144
Name = 'myBastion'
119-
PublicIpAddress = $publicip
145+
PublicIpAddress = $bastionip
120146
VirtualNetwork = $vnet
121147
}
122148
New-AzBastion @bastion -AsJob

0 commit comments

Comments
 (0)