Search code examples
azureazure-rm-templateazure-appserviceazure-bicep

Setting the `customDomainVerificationId` property on an AppService in a Bicep deployment has no effect


I'm creating an App Service via Bicep, and trying to set the "Custom Domain Verification ID" property, so that I can setup the correct TXT records for verification (before the Bicep deployments run).

resource app_service 'Microsoft.Web/sites@2021-01-15' = {
  name: name
  location: location
  properties: {
    serverFarmId: plan_id
    siteConfig: {
      netFrameworkVersion: 'v4.6'
    }
    customDomainVerificationId: custom_domain_verification_id
  }
}

But, the value I set isn't respected and will be something else under "Custom Domains" on the App Service.

Is this property meant to be read only?

Update

Seems like this might be a readonly property actually. It's the same across the entire Subscription, so makes sense that it can't be set on an individual AppService. Reported an issue here.


Solution

  • Yes, this property should be read only. It’s filled when app service is created.

    If you don’t mind, please report this inaccuracy on https://aka.ms/bicep-type-issues