Skip to content

Latest commit

 

History

History
88 lines (56 loc) · 5.29 KB

quick-create-template.md

File metadata and controls

88 lines (56 loc) · 5.29 KB
title titleSuffix description services author ms.service ms.topic ms.date ms.author ms.custom
Quickstart: Direct web traffic using a Resource Manager template
Azure Application Gateway
In this quickstart, you learn how to use a Resource Manager template to create an Azure Application Gateway that directs web traffic to virtual machines in a backend pool.
application-gateway
vhorne
application-gateway
quickstart
08/27/2020
victorh
mvc

Quickstart: Direct web traffic with Azure Application Gateway - ARM template

In this quickstart, you use an Azure Resource Manager template (ARM template) to create an Azure Application Gateway. Then you test the application gateway to make sure it works correctly.

[!INCLUDE About Azure Resource Manager]

You can also complete this quickstart using the Azure portal, Azure PowerShell, or Azure CLI.

[!INCLUDE updated-for-az]

If your environment meets the prerequisites and you're familiar with using ARM templates, select the Deploy to Azure button. The template will open in the Azure portal.

Deploy to Azure

Prerequisites

Review the template

For the sake of simplicity, this template creates a simple setup with a public front-end IP, a basic listener to host a single site on the application gateway, a basic request routing rule, and two virtual machines in the backend pool.

The template used in this quickstart is from Azure Quickstart Templates

:::code language="json" source="~/quickstart-templates/ag-docs-qs/azuredeploy.json":::

Multiple Azure resources are defined in the template:

Deploy the template

Deploy the ARM template to Azure:

  1. Select Deploy to Azure to sign in to Azure and open the template. The template creates an application gateway, the network infrastructure, and two virtual machines in the backend pool running IIS.

    Deploy to Azure

  2. Select or create your resource group, type the virtual machine administrator user name and password.

  3. Select Review + Create and then select Create.

    The deployment can take 20 minutes or longer to complete.

Validate the deployment

Although IIS isn't required to create the application gateway, it's installed to verify if Azure successfully created the application gateway. Use IIS to test the application gateway:

  1. Find the public IP address for the application gateway on its Overview page.Record application gateway public IP address Or, you can select All resources, enter myAGPublicIPAddress in the search box, and then select it in the search results. Azure displays the public IP address on the Overview page.

  2. Copy the public IP address, and then paste it into the address bar of your browser to browse that IP address.

  3. Check the response. A valid response verifies that the application gateway was successfully created and can successfully connect with the backend.

    Test application gateway

    Refresh the browser multiple times and you should see connections to both myVM1 and myVM2.

Clean up resources

When you no longer need the resources that you created with the application gateway, delete the resource group. This removes the application gateway and all the related resources.

To delete the resource group, call the Remove-AzResourceGroup cmdlet:

Remove-AzResourceGroup -Name <your resource group name>

Next steps

[!div class="nextstepaction"] Manage web traffic with an application gateway using the Azure CLI