You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/storage/files/storage-files-configure-s2s-vpn.md
+18-4Lines changed: 18 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ description: Learn how to configure a site-to-site (S2S) VPN for use with Azure
4
4
author: khdownie
5
5
ms.service: azure-file-storage
6
6
ms.topic: how-to
7
-
ms.date: 09/05/2024
7
+
ms.date: 09/06/2024
8
8
ms.author: kendownie
9
9
---
10
10
@@ -150,14 +150,28 @@ To add a new or existing virtual network to your storage account, follow these s
150
150
az login
151
151
```
152
152
153
-
1. If you want to add a new virtual network and gateway subnet, run the following script. If you have an existing virtual network that you want to use, then skip this step and proceed to step 3. Be sure to replace `<your-subscription-id>`, `<resource-group>`, and `<storage-account-name>` with your own values. Replace `<virtual-network-name>` with the name of the new virtual network you want to create. The `--address-prefix` and `--subnet-prefix` parameters define the IP address blocks for the virtual network and the subnet, so replace those with your respective values. The virtual network will be created in the same region as the resource group.
153
+
1. If you want to add a new virtual network and gateway subnet, run the following script. If you have an existing virtual network that you want to use, then skip this step and proceed to step 3. Be sure to replace `<your-subscription-id>`, `<storage-account-name>`, and `<resource-group>` with your own values. Replace `<virtual-network-name>` with the name of the new virtual network you want to create. The `--address-prefix` and `--subnet-prefix` parameters define the IP address blocks for the virtual network and the subnet, so replace those with your respective values. The virtual network will be created in the same region as the resource group.
154
154
155
155
```azurecli-interactive
156
156
# Set your subscription
157
157
az account set --subscription "<your-subscription-id>"
158
158
159
-
# Create a virtual network and subnet. Virtual network gateway can only be created in subnet with name 'GatewaySubnet'.
# Virtual network gateway can only be created in subnet with name 'GatewaySubnet'.
164
+
subnetName="GatewaySubnet"
165
+
vnetAddressPrefix = "10.0.0.0/16" # Update this address per your requirements
166
+
subnetAddressPrefix="10.0.0.0/24" # Update this address per your requirements
167
+
168
+
# Create a virtual network and subnet
169
+
az network vnet create \
170
+
--resource-group $resourceGroup \
171
+
--name $vnetName \
172
+
--address-prefix $vnetAddressPrefix \
173
+
--subnet-name $subnetName \
174
+
--subnet-prefix $subnetAddressPrefix
161
175
```
162
176
163
177
1. If you created a new virtual network and subnet in the previous step, then skip this step. If you have an existing virtual network you want to use, you must first create a [gateway subnet](../../vpn-gateway/vpn-gateway-about-vpn-gateway-settings.md#gwsub) on the virtual network before you can deploy a virtual network gateway.
0 commit comments