Skip to content

Commit e45ec14

Browse files
committed
removed code indent for uniform look and feel
1 parent 23ee6d1 commit e45ec14

File tree

1 file changed

+43
-43
lines changed

1 file changed

+43
-43
lines changed

articles/azure-cache-for-redis/cache-private-link.md

Lines changed: 43 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -248,70 +248,70 @@ Get-AzPrivateEndpoint -Name $PrivateEndpointName -ResourceGroupName $ResourceGro
248248
To remove a private endpoint, use the following PowerShell command:
249249

250250
```azurepowershell-interactive
251-
Remove-AzPrivateEndpoint -Name $PrivateEndpointName -ResourceGroupName $ResourceGroupName
251+
Remove-AzPrivateEndpoint -Name $PrivateEndpointName -ResourceGroupName $ResourceGroupName
252252
```
253253

254254
## Create a private endpoint using Azure CLI
255255

256256
To create a private endpoint named *myPrivateEndpoint* for an existing Azure Cache for Redis instance, run the following Azure CLI script. Replace the variable values with the details for your environment:
257257

258258
```azurecli-interactive
259-
# Resource group where the Azure Cache for Redis and virtual network resources are located
260-
ResourceGroupName="myResourceGroup"
261-
262-
# Subscription ID where the Azure Cache for Redis and virtual network resources are located
263-
SubscriptionId="<your Azure subscription ID>"
264-
265-
# Name of the existing Azure Cache for Redis instance
266-
redisCacheName="mycacheInstance"
267-
268-
# Name of the virtual network to create
269-
VNetName="myVnet"
270-
271-
# Name of the subnet to create
272-
SubnetName="mySubnet"
273-
274-
# Name of the private endpoint to create
275-
PrivateEndpointName="myPrivateEndpoint"
276-
277-
# Name of the private endpoint connection to create
278-
PrivateConnectionName="myConnection"
279-
280-
az network vnet create \
281-
--name $VNetName \
282-
--resource-group $ResourceGroupName \
283-
--subnet-name $SubnetName
284-
285-
az network vnet subnet update \
286-
--name $SubnetName \
287-
--resource-group $ResourceGroupName \
288-
--vnet-name $VNetName \
289-
--disable-private-endpoint-network-policies true
290-
291-
az network private-endpoint create \
292-
--name $PrivateEndpointName \
293-
--resource-group $ResourceGroupName \
294-
--vnet-name $VNetName \
295-
--subnet $SubnetName \
296-
--private-connection-resource-id "/subscriptions/$SubscriptionId/resourceGroups/$ResourceGroupName/providers/Microsoft.Cache/Redis/$redisCacheName" \
297-
--group-ids "redisCache" \
298-
--connection-name $PrivateConnectionName
259+
# Resource group where the Azure Cache for Redis and virtual network resources are located
260+
ResourceGroupName="myResourceGroup"
261+
262+
# Subscription ID where the Azure Cache for Redis and virtual network resources are located
263+
SubscriptionId="<your Azure subscription ID>"
264+
265+
# Name of the existing Azure Cache for Redis instance
266+
redisCacheName="mycacheInstance"
267+
268+
# Name of the virtual network to create
269+
VNetName="myVnet"
270+
271+
# Name of the subnet to create
272+
SubnetName="mySubnet"
273+
274+
# Name of the private endpoint to create
275+
PrivateEndpointName="myPrivateEndpoint"
276+
277+
# Name of the private endpoint connection to create
278+
PrivateConnectionName="myConnection"
279+
280+
az network vnet create \
281+
--name $VNetName \
282+
--resource-group $ResourceGroupName \
283+
--subnet-name $SubnetName
284+
285+
az network vnet subnet update \
286+
--name $SubnetName \
287+
--resource-group $ResourceGroupName \
288+
--vnet-name $VNetName \
289+
--disable-private-endpoint-network-policies true
290+
291+
az network private-endpoint create \
292+
--name $PrivateEndpointName \
293+
--resource-group $ResourceGroupName \
294+
--vnet-name $VNetName \
295+
--subnet $SubnetName \
296+
--private-connection-resource-id "/subscriptions/$SubscriptionId/resourceGroups/$ResourceGroupName/providers/Microsoft.Cache/Redis/$redisCacheName" \
297+
--group-ids "redisCache" \
298+
--connection-name $PrivateConnectionName
299299
```
300300

301301
## Retrieve a private endpoint using Azure CLI
302302

303303
To get the details of a private endpoint, use the following CLI command:
304304

305305
```azurecli-interactive
306-
az network private-endpoint show --name MyPrivateEndpoint --resource-group MyResourceGroup
306+
az network private-endpoint show --name MyPrivateEndpoint --resource-group MyResourceGroup
307307
```
308308

309309
## Remove a private endpoint using Azure CLI
310310

311311
To remove a private endpoint, use the following CLI command:
312312

313313
```azurecli-interactive
314-
az network private-endpoint delete --name MyPrivateEndpoint --resource-group MyResourceGroup
314+
az network private-endpoint delete --name MyPrivateEndpoint --resource-group MyResourceGroup
315315
```
316316

317317
## FAQ

0 commit comments

Comments
 (0)