Hi,
I am using ARM template to deploy a service fabric cluster with a data disk. Following the configuration for the data disk that I have -
"storageProfile": {
"imageReference": {
"publisher": "[parameters('vmImagePublisher')]",
"offer": "[parameters('vmImageOffer')]",
"sku": "[parameters('vmImageSku')]",
"version": "[parameters('vmImageVersion')]"
},
"osDisk": {
"caching": "ReadOnly",
"createOption": "FromImage",
"managedDisk": {
"storageAccountType": "[parameters('storageAccountType')]"
}
},
"dataDisks": [
{
"diskSizeGB": 1024,
"lun": 0,
"createOption": "Attach",
"managedDisk": {
"id": "[resourceId('Microsoft.Compute/disks', 'disk1')]"
}
}
]
}
On deploying it throws the following error:
{
"status": "Failed",
"error": {
"code": "InvalidParameter",
"target": "dataDisk.managedDisk.id",
"message": "Parameter 'dataDisk.managedDisk.id' is not allowed."
}
}
The documentation for ARM template does support the above. Here is the link [Manged Disk Parameters] (https://learn.microsoft.com/en-us/azure/templates/microsoft.compute/virtualmachines?tabs=json#manageddiskparameters)
What am I missing? Why does it throw invalid error?
Note - Also, tagging it as Azure managed disks. There are no tags related to Azure resource manager templates. It was not listing any at least.