microsoft / azure-container-apps

Roadmap and issues for Azure Container Apps
MIT License
355 stars 27 forks source link

Default CPU value for initContainers deployed with bicep is 0.5, but az cli cannot update the app, complaining that 0.5 is invalid for init containers: #1189

Open onionhammer opened 3 weeks ago

onionhammer commented 3 weeks ago

Please provide us with the following information:

This issue is a: (mark with an x)

Issue description

Default CPU value for initContainers deployed with bicep is 0.5, but az cli cannot update the app, complaining that 0.5 is invalid for init containers:

'ERROR: (ContainerAppInitContainersInvalidCpu) Invalid CPU value 0.5 for init container app-migrations ,an init container can not be allocated more CPU than the total CPU 0.25 allocated for all app containers.'

Steps to reproduce

  1. Deploy an ACA app with an initcontainer, without specifying cpu/memory
  2. Run az containerapp update to attempt to update the --image

Expected behavior [What you expected to happen.] The container image should be updated

Actual behavior [What actually happened.] 'ERROR: (ContainerAppInitContainersInvalidCpu) Invalid CPU value 0.5 for init container app-migrations ,an init container can not be allocated more CPU than the total CPU 0.25 allocated for all app containers.'