AI-200 · 1.1.2 · Develop containerized solutions on Azure
ACR Tasks
Build and run images by using Azure Container Registry Tasks
Build in Azure on demand or from commit, base-image, and timer triggers, without a local Docker engine.
Choose the task type

Use az acr build for an on-demand cloud build. Create a reusable task when the build should run again from source changes, updates, a schedule, or a manual run.
Know the automatic triggers
- Code is committedCommit triggerEnabled by default for a Git context
- A pull request changesPull request triggerEnable it explicitly
- A stable changesBase image triggerThe task must have run before so dependencies are known
- A cron schedule is reachedTimer trigger
Git triggers need a personal access token so can create the repository webhook.
Build, test, then push
version: v1.1.0
steps:
- id: build-api
build: -t $Registry/shop/orders-api:$ID .
- id: smoke-test
cmd: $Registry/shop/orders-api:$ID
- push: ["$Registry/shop/orders-api:$ID"]
when: ["smoke-test"]
A cmd step runs a container. when makes later steps wait for successful dependencies.
Read unattended runs
Automatically triggered runs store their output instead of streaming it to your terminal. Use az acr task logs when you need the build or test output.
Key points
- : `az build` builds and pushes without local Docker
- Commit trigger: enabled by default for a Git task context
- Pull request trigger: opt in; Git triggers need a personal access token
- trigger: tracks updates under the same stable tag
- : combine `build`, `cmd`, `push`, and `when`
- Logs: automatic runs store output for later inspection
Click an underlined term for a one-line explanation, or see them all in the glossary .
Exam trap
A update triggers a rebuild only for new content under the same stable tag, never for a new version tag.
Sources · 3 Microsoft Learn pages Show ▾
- Automate container builds with ACR Tasks (Azure Container Registry)
- YAML reference for ACR Tasks (Azure Container Registry)
- Base image updates in ACR Tasks (Azure Container Registry)
Checked on October 4, 2026. Report a problem
Go deeper on Microsoft Learn
- Automate container builds with ACR Tasks (Azure Container Registry)
- YAML reference for ACR Tasks (Azure Container Registry)
- Base image updates in ACR Tasks (Azure Container Registry)
Checked against Microsoft Learn on October 4, 2026. Report a problem with this card