问题
In documentation, it is mentioned that apiVersion
property should be used to specify the REST API version of the resource.
However, in this 101-automation-configuration template,
api version mentioned here for resource type Microsoft.Resources/deployments
is 2018-02-01
.
If we look at the available versions for Microsoft.Resources/deployments
, we see following values:
2017-08-01,2017-06-01,2017-05-10,2017-05-01,2017-03-01,2016-09-01,2016-07-01,2016-06-01,2016-02-01,2015-11-01,2015-01-01,2014-04-01-preview
. I am not sure from where this 2018-02-01
version is coming.
The api version 2018-02-01
is used in nested templates of this template.
(Template link is given in 'templateLink' property).
So, what does api version signifies in this template resource?
回答1:
So basically arm templates just describe how and which rest api calls you want to perform. api version is appended to the path of the call, so the resource provider can know which version are you working against.
this particular version is either a typo or internal only something. might be a regional thing. as far as I know there are internal use only regions.
edit: I've assumed you checked the api versions, but I clearly see the api version available:
(Get-AzureRmResourceProvider -ProviderNamespace 'Microsoft.Resources').ResourceTypes |
? resourcetypename -eq deployments | ft resourcetypename, apiversions
ResourceTypeName ApiVersions
---------------- -----------
deployments {2018-02-01, 2018-01-01, 2017-08-01, 2017-06-01...}
来源:https://stackoverflow.com/questions/49691628/what-is-the-use-of-apiversion-property-in-resource-section-resources-array-o