1 minute read

An Error

Did I tear my bicep? No but I got an error. Whilst trying to deploy a network with Bicep using Azure DevOps I received the error

Error: Code=InvalidTemplateDeployment; Message=The template deployment ‘deploy_bicep003_20210505094331’ is not valid according to the validation procedure. The tracking id is ‘4bdec1fe-915d-4735-a1c1-7b56fbba0dc2’. See inner errors for details.

Unfortunately that was all that I had. I had to find the inner error for details

Try the deployment log on the Resource Group

As I know that the Bicep deployments are logged in Azure under the Resource Groups deployment I looked there first but there were no entries (obviously Rob, there had been no deployment)

So I navigated to the home page of the Azure Portal and searched for Activity log.


I searched for the name of the deployment deploy_bicep003_20210505094331 and saw


clicking on the link showed me this with the relevant information hidden in the JSON


Resource name {‘name’:’subnet1’,’addressPrefix’:’’}.name is invalid.


I had made a mistake in my resource definition for the subnets. I had used

subnets:  [for item in subnets:{
  name: '${item}.name'
  properties: {
    addressPrefix: '${item}.addressPrefix'

where I should have used

subnets:  [for item in subnets:{
  name: '${item.name}'
  properties: {
    addressPrefix: '${item.addressPrefix}'

Every day is a learning day.