-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
APIM additional_location's zones was not able to unset, caused error when using additional_location which does not support zones #17515
Comments
Workaround solution in case anyone need this urgently. In summary, we will have to
To add location manually:
{
"properties": {
"additionalLocations": [
{
"location": "canadaeast",
"platformVersion": "stv2",
"sku": {
"name": "Premium",
"capacity": 2
},
"zones": [],
"publicIpAddressId": null,
"virtualNetworkConfiguration": {
"subnetResourceId": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/Microsoft.Network/virtualNetworks/{VNETName}/subnets/{SubnetName}"
}
}
]
}
}
az rest --method PATCH --header "Accept=application/json" \ ─╯
--url 'https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{APIMInstanceName}?api-version=2021-08-01' \
--body @apim-cae-location.json
|
@manicminer can you please add the |
Hi @AdamCoulterOz Thanks for looking after this issue. We are building a premium APIM on Australia East with an additional location of Australia Southeast. This bug is blocking us from creating the additional location, as well as any following updates. Please help to fix the issue. It is muchly appreciated. |
I am having the same issue, with UK South/UK West and Australia East/Australia Southeast. It appears that the function that constructs the additional locations body elements to send to the API does not reference the additional location block argument of zones, but references the "root" or primary location zones argument. I have raised #23943 that fixes this, and adds an acceptance test that fails without the change I have made. |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. |
Is there an existing issue for this?
Community Note
Terraform Version
1.2.4
AzureRM Provider Version
3.4.0
Affected Resource(s)/Data Source(s)
azurerm_api_management
Terraform Configuration Files
Debug Output/Panic Output
Expected Behaviour
Should be able to create APIM primary instance with 2 unit, 2 zone, secondary instance with 2 unit with no zone.
Actual Behaviour
Error from the
additional_location
block, probably due to thezones
is enable in primary.additional_location
block is trying to enable using the zones configuration from the primary but since the additional location is canadaeast which do not have availability zone, it failed with following error. Passing in[]
ornull
couldn't help to unset the zones because that seems to evaluate as 'omitted' instead of replacing the zone setup for the additional location.Steps to Reproduce
terraform apply
Important Factoids
No response
References
No response
The text was updated successfully, but these errors were encountered: