InvalidTemplateDeployment error when deploying Bicep template in Build reusable Bicep templates by using parameters module

Alexis Lessard 0 Reputation points
2024-10-02T16:21:12.5533333+00:00

I'm completing the Fundamentals of Bicep learning path. I'm in Build reusable Bicep templates by using parameters module. However, when trying to run the provided solution, my deployment is blocked with the following errors:

{"code": "InvalidTemplateDeployment", "message": "The template deployment 'main' is not valid according to the validation procedure. The tracking id is '2f9a0efa-551c-44e7-a201-8c1eb17b6103'. See inner errors for details."}

Inner Errors: 
{"code": "ValidationForResourceFailed", "message": "Validation failed for a resource. Check 'Error.Details[0]' for more information."}

Inner Errors: 
{"code": "SubscriptionIsOverQuotaForSku", "message": "This region has quota of 0 instances for your subscription. Try selecting different region or SKU."}

I've copy-pasted the exact solution provided by the exercice. The solution's region is eastus, but I've tried it with westus3 and westus2, without any change. I'm sure I've set the correct subscription and resource group as my defaults. Could it just be because of a malfunction in my sandbox?

This question is related to the following Learning Module

Azure Training
Azure Training
Azure: A cloud computing platform and infrastructure for building, deploying and managing applications and services through a worldwide network of Microsoft-managed datacenters.Training: Instruction to develop new skills.
1,760 questions
{count} votes

1 answer

Sort by: Most helpful
  1. kguntaka 3,405 Reputation points Microsoft Vendor
    2024-10-03T02:42:19.2733333+00:00

    Hi Alexis Lessard,

    Replace dev/QA/Prod, etc. with the appropriate extent name and an extension like main.parameters.dev.json when saving the parameters file. You can fix your issue by trying a different region.
    For further information, kindly click the following URL:
    To Build reusable Bicep templates by using parameters module

    If you have any additional questions, please let us know in the comments. We’re happy to assist further. 

    If you found the answer helpful, please click on Upvote and Accept Answer. This will help other community members.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.