Skill 3.1.2
Modify an existing Azure Resource Manager template
Key Concepts
Typical changes are replacing a hard-coded value with a parameter (adding the parameter definition and changing the property to [parameters('name')]), adding allowedValues to limit SKUs, computing names in variables with functions such as uniqueString(resourceGroup().id), adding a resource with the correct apiVersion and a dependsOn entry for the resources it needs, and adding an output such as a public IP address. The copy element deploys several instances of a resource or property, and the condition element deploys a resource only when an expression is true.
Templates are edited in Visual Studio Code with the Azure Resource Manager Tools extension or in the portal's Template specs and Deploy a custom template editors, which can also add resources from quickstart templates. Secrets should never be placed in templates; a parameter file can reference a Key Vault secret instead. Testing a modified template with what-if before deploying shows the changes it will make.