You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Property needs to be set on 'null' instead of empty string '', otherwise the pipeline crashes with a BadRequest error. At the same time, setting it to 'null' gives a warning in Vistual Studio Code: The property "logAnalyticsWorkspaceResourceID" expected a value of type "string" but the provided value is of type "null | string".bicep(BCP036)
Relevant code:
resourceaksClusterRes'Microsoft.ContainerService/managedClusters@2020-09-01' = {
name: aksCluster.namelocation: resourceGroup().locationtags: tagssku: {
name: 'Basic'tier: aksCluster.sla
}
properties: {
kubernetesVersion: aksCluster.kubernetesVersionaddonProfiles: {
omsAgent: {
enabled: aksCluster.logAnalyticsWorkspace.enableContainerMonitoringconfig: {
//needs to be set to null, not '', otherwise badRequest error:logAnalyticsWorkspaceResourceID: aksCluster.logAnalyticsWorkspace.enableContainerMonitoring ? logAnalyticsWorkspace.id : null
}
}
ingressApplicationGateway: {
enabled: !empty(aksCluster.network.ingressApplicationGateway.name)
config: {
//needs to be set to null, not '', otherwise badRequest error:applicationGatewayId: !empty(aksCluster.network.ingressApplicationGateway.name) ? ingressApplicationGateway.id : null
}
}
}
agentPoolProfiles: [
agentPoolProfiles[0]
]
}
}
To Reproduce
Replace both the 'null'-s in code above to '' and pipeline crashes with BadRequest error.
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered:
Bicep version
0.4.63
Describe the bug
Property needs to be set on 'null' instead of empty string '', otherwise the pipeline crashes with a BadRequest error. At the same time, setting it to 'null' gives a warning in Vistual Studio Code:
The property "logAnalyticsWorkspaceResourceID" expected a value of type "string" but the provided value is of type "null | string".bicep(BCP036)
Relevant code:
To Reproduce
Replace both the 'null'-s in code above to '' and pipeline crashes with BadRequest error.
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: