I have sample ARM template given below. The fields subscription, resource group and location are provided in first section ARM template to user while deploying and parameters section is provided after this. Resource group is drop down field provided by Azure ARM itself, where I need to provide any one resource group as default resource group present in list. How can this possible?
{
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"writePermission": {
"defaultValue": "No",
"allowedValues": [
"No",
"Yes"
],
"type": "String",
"metadata": {
"description": "the permission type"
}
}
},
"variables": {
"location": "[resourceGroup().location]",
"templateUri": "[deployment().properties.templateLink.uri]"
},
"resources": [
],
"outputs": {
"result": {
"type": "String",
"value": "[variables('templateUri')]"
}
}
}
This is how template is rendered.
Expected solution: Instead of blank value in resource group, it should be pre-populated with first field from drop-down of resource group.