Hi Limopasit, Anattapol (Allianz Technology),
In order to create an Azure Container App, under your resource group create an environment
az containerapp env create \
--name arkorg-env \
--resource-group arkorg \
--location centralindia
Check if the environment was created successfully
az containerapp env show --name arkorg-env --resource-group arkorg
Now deploy your container app. I am deploying in Nginx on it
az containerapp create \
--name mycontainerapp \
--resource-group arkorg \
--environment arkorg-env \
--image nginx \
--target-port 80 \
--ingress external \
--cpu 0.5 \
--memory 1.0Gi
Check the container app's status
Looks good.
fetch the URL and test it out
az containerapp show --name mycontainerapp --resource-group arkorg --query "properties.configuration.ingress.fqdn" --output tsv
Works fine.
If the deployment fails with operation expired
, proceed to troubleshooting.
Check logs if revision exists
az containerapp logs show --name mycontainerapp --resource-group arkorg
Check for activity logs-
az monitor activity-log list --resource-group arkorg
If no revision exists, the issue is likely image pull failure or resource quota limits.
If CPU/memory is maxed out, try a different region
If operation is failing because of image pull issue then let me know if you are using a private container registry?
If so , update your aca with the private acr using it's username and password
az containerapp update \
--name mycontainerapp \
--resource-group arkorg \
--image myregistry.azurecr.io/myimage:v1 \
--registry-server myregistry.azurecr.io \
--registry-username <USERNAME> \
--registry-password <PASSWORD>
MS Doc- Troubleshoot container create failures in Azure Container Apps | Microsoft Learn