- Run
to login the Azure CLI with your account.
az login
- Create a Terraform sheet
provider "azurerm" { version = "=1.44.0" subscription_id = ${SUBSCRIPTION_ID} } resource "azurerm_resource_group" "rg" { location = ${LOCATION} name = ${NAME} } resource "azurerm_container_registry" "acr" { name = ${NAME} resource_group_name = azurerm_resource_group.rg.name location = azurerm_resource_group.rg.location sku = "Basic" }```
- Run
terraform apply
to deploy an ACR.
- Create a personal access token (e.g., Github) and save it in a file
access.token
. - Run
to create a task to execute the task definition in
az acr task create --name hello-world-task -f hello-world-task.yaml -c https://github.com/marquardts/test-acr.git --git-access-token `cat access.token`
hello-world-task.yaml
from the repo. By default, on-commit and base-image change triggers are active.
- Does not work with Github Enterprise