はじめに
メモ残しとく
コマンド(アドレスプールにVMのIPを削除する)
# Set variables for the resource group and application gateway names
$resource_group_name="pro-nabehiro-001"
$app_gateway_name="nbfr151x"
$backend_pool_name = "appGatewayBackendPool"
# show address pool ip addresses from the application gateway
az network application-gateway address-pool list --resource-group $resource_group_name --gateway-name $app_gateway_name
# Detach the backend pool from the application gateway
az network application-gateway address-pool delete --resource-group $resource_group_name --gateway-name $app_gateway_name -name $backend_pool_name --remove backendAddresses
# show address pool ip addresses from the application gateway
az network application-gateway address-pool list --resource-group $resource_group_name --gateway-name $app_gateway_name
コマンド(アドレスプールにVMのIPを接続する)
# Set variables for the resource group and application gateway names
$resource_group_name="pro-nabehiro-001"
$app_gateway_name="nbfr151x"
$backend_pool_name = "appGatewayBackendPool"
$vm_ips = @("10.0.0.4", "10.0.0.5", "10.0.0.6")
# show address pool ip addresses from the application gateway
az network application-gateway address-pool list --resource-group $resource_group_name --gateway-name $app_gateway_name
# atach the backend pool from the application gateway
az network application-gateway address-pool update --resource-group $resource_group_name --gateway-name $app_gateway_name --name $backend_pool_name --server $vm_ips
# show address pool ip addresses from the application gateway
az network application-gateway address-pool list --resource-group $resource_group_name --gateway-name $app_gateway_name