Skip to content

[Bug Report]: cdn/profile/endpoint - dependsOn missing for endpoint_origins on endpoint #4459

Description

Describe the bug

While deploying a cdn profile with endpoint, both the origin and endpoint are deployed at the same time and cause the endpoint_origins to failed with a not found error on the endpoint. I fixed the issus on my local repository with dependsOn: [ endpoint ] on endpoint_origin in the module cdn/profile/endpoint/main.bicep

To reproduce

Create a cdn profile with an endpoint

Code snippet

var location = 'CanadaCentral'
var cdneName  = 'endpointname01' 
var cdnpName = 'profilename01'
var url = '[teststorageaccount].blob.core.windows.net'

module profile 'modules/cdn/profile/main.bicep' = {  
  name: '${uniqueString(deployment().name, location)}-test-cdnpafd'
  params: {
    name: cdnpName
    sku: 'Standard_Microsoft'
    endpointProperties: {
      name: cdneName
      location: location
      isCompressionEnabled: false
      isHttpAllowed: false
      isHttpsAllowed: true
      origins: [
        {
          name: 'cdneporitest01'
          properties: {
            hostName:  url
            httpPort: 80
            httpsPort: 443
            originHostHeader: url
            enabled: true
            weight: 1000
            priority: 1  
          }
        }  
      ]
    }
    location: 'global'
  }
}

Relevant log output

details":[{"code":"NotFound","message":"The resource cannot be found."},{"code":"NotFound","message":"The requested resource was not found."

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

bugSomething isn't working

Type

No type

Projects

  • Status
    Closed

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions