Question:I use Azure ARM templates for deploying Azure resources. Now I have been asked to convert a few of the ARM templates into Terraform files.
I am new to terraform world. I just went through some online examples of creating Azure resources using Terraform’s AzureRM provider. but, nowhere did I find a way to set the API version for the Azure resource provider.
For example, In the ARM template, we can specify “apiVersion” for any resources but in the Terraform there is no option to choose the API version.
Does anyone know how to choose API Version in Terraform for Azure?
Answer:In Terrform we don’t speficy the
api versionfor each resource likewise we do in ARM template.
In terraform we only use the AzureRM provider version. If you are not mentioning specific version it will take the latest AzureRM provider version
The Azure Provider can be used to configure infrastructure in Microsoft Azure using the Azure Resource Manager API’s.
For more information please refer this official terarform document
If you have better answer, please add a comment about this, thank you!