Question

Difficulty: MediumManage Container Images in Azure Container Registry

You are configuring a deployment pipeline on a non-Azure container runner that needs to push images to an Azure Container Registry (ACR) named registry2026.azurecr.io. The runner does not have the Azure CLI installed. You create a repository-scoped token named pipeline-token that has permissions restricted to the target repository. Which command and credentials should you use to authenticate the container runner with the registry?

  1. Run `docker login registry2026.azurecr.io` using `pipeline-token` as the username and one of the generated passwords as the password.Answer
  2. B
    Run `docker login registry2026` using `00000000-0000-0000-0000-000000000000` as the username and the token name as the password.
  3. C
    Run `az acr login --name registry2026` using the token name as the username and the token value as the password.
  4. D
    Run `docker login registry2026.azurecr.io` using the system-assigned managed identity client ID as the username and the token value as the password.

Answer

Run `docker login registry2026.azurecr.io` using `pipeline-token` as the username and one of the generated passwords as the password.
The correct answer is to run the standard `docker login` command targeting the fully qualified registry name (`registry2026.azurecr.io`) using the token name (`pipeline-token`) as the username and one of the generated secret passwords as the password. This provides secure, scoped access without needing the Azure CLI or broad admin credentials on a non-Azure runner.

Step-by-Step Solution

1
Identify the authentication requirements of the container runner.
The runner is a non-Azure resource and does not have the Azure CLI installed, meaning standard Azure CLI authentication methods (like `az acr login`) cannot be used.
This establishes that we must use standard Docker CLI commands (`docker login`) with explicit credentials.
2
Determine the proper login server name.
The login server name is `registry2026.azurecr.io`.
Docker CLI commands require the fully qualified registry domain name rather than just the registry name prefix.
3
Apply repository-scoped token authentication rules.
For repository-scoped tokens, the token name (`pipeline-token`) acts as the username, and the generated token password acts as the password.
This complies with the Azure Container Registry token-based authentication specification.

Key Concept

Azure Container Registry repository-scoped token authentication via Docker CLI
Estimated Time:1m 30s
Rate this question