Before we get started on this section, make sure that you have installed the Azure Development Workload, as shown in the following screenshot:
Azure Development Workload in Visual Studio
Let's take a look at the basic structure of the template system used to deploy resources to Azure:
{
"$schema": "http://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#", "contentVersion": "",
"parameters": { },
"variables": { },
"functions": { },
"resources": [ ],
"outputs": { }
}
Let's look at what the elements in the schema mean and whether some of them are required:
Now that we have seen how the template is structured, let's look at how a vanilla virtual machine is deployed to put it all together. You can create an ARM template project in Visual Studio by selecting the Azure Resource Group project under New Projects, as shown in the following screenshot:
Visual Studio – Azure Resource Group