Azure / ResourceModules

This repository includes a CI platform for and collection of mature and curated Bicep modules. The platform supports both ARM and Bicep and can be leveraged using GitHub actions as well as Azure DevOps pipelines.
https://aka.ms/carml
MIT License
726 stars 459 forks source link

[Utilities] Detect deployments to API versions that do not exist in regions that are used for modules testing #2587

Open ahmadabdalla opened 1 year ago

ahmadabdalla commented 1 year ago
          @eriqua 

Having updated the API to the latest stable version 2022-09-09. I see there are some limitations in relation to the region where that API is available., although it is documented in the template reference doc

  Status Message: No registered resource provider found for location 'westeurope' and API version '2022-09-09' for type 'scalingplans'. The supported api-versions are '2019-01-23-preview, 2019-09-24-preview, 2019-12-10-preview, 2020-09-21-preview, 2020-10-19-preview, 2020-11-02-preview, 2020-11-10-preview, 2021-01-14-preview, 2021-02-01-preview, 2021-03-09-preview, 2021-04-01-preview, 2021-05-13-preview, 2021-09-03-preview, 2022-01-12-privatepreview, 2022-02-10-preview, 2022-04-01-preview, 2021-07-12'. The supported locations are 'uksouth, ukwest, japaneast, australiaeast, canadaeast, canadacentral, northeurope, westeurope, eastus, eastus2, westus, westus2, westus3, northcentralus, southcentralus, westcentralus, centralus'. (Code:NoRegisteredProviderFound)

  Status Message: At least one resource deployment operation failed. Please list deployment operations for details. Please see https://aka.ms/DeployOperations for usage details. (Code: DeploymentFailed)
   - {
    "error": {
      "code": "NoRegisteredProviderFound",
      "message": "No registered resource provider found for location 'westeurope' and API version '2022-09-09' for type 'scalingplans'. The supported api-versions are '2019-01-23-preview, 2019-09-24-preview, 2019-12-10-preview, 2020-09-21-preview, 2020-10-19-preview, 2020-11-02-preview, 2020-11-10-preview, 2021-01-14-preview, 2021-02-01-preview, 2021-03-09-preview, 2021-04-01-preview, 2021-05-13-preview, 2021-09-03-preview, 2022-01-12-privatepreview, 2022-02-10-preview, 2022-04-01-preview, 2021-07-12'. The supported locations are 'uksouth, ukwest, japaneast, australiaeast, canadaeast, canadacentral, northeurope, westeurope, eastus, eastus2, westus, westus2, westus3, northcentralus, southcentralus, westcentralus, centralus'."
    }
  } (Code:BadRequest)

Do we have a CARML defined preference on using an API that is available in most regions vs. just the latest version?

Originally posted by @ahmadabdalla in https://github.com/Azure/ResourceModules/issues/2536#issuecomment-1378684253

AlexanderSehr commented 1 year ago

Following a discussion we'd opt to provide guidance around this issue in the Wiki documentation and, for example, suggest to downgrade to a non-latest version if not available in the selected test region/location.