0
0
Azurecloud~10 mins

ACR image building and pushing in Azure - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the command to log in to Azure Container Registry (ACR).

Azure
az acr [1] --name myRegistry
Drag options to blanks, or click blank then click option'
Apush
Blogin
Cbuild
Dcreate
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'push' instead of 'login' will try to push an image without authentication.
Using 'build' or 'create' does not log you in.
2fill in blank
medium

Complete the command to build a Docker image and push it to ACR in one step.

Azure
az acr [1] --registry myRegistry --image myapp:v1 .
Drag options to blanks, or click blank then click option'
Acreate
Bpush
Clogin
Dbuild
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'push' alone requires the image to be built first.
Using 'login' or 'create' does not build images.
3fill in blank
hard

Fix the error in the command to push a local Docker image to ACR.

Azure
docker [1] myRegistry.azurecr.io/myapp:v1
Drag options to blanks, or click blank then click option'
Apush
Bbuild
Clogin
Drun
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'build' tries to create an image instead of uploading.
Using 'login' is for authentication, not pushing.
Using 'run' starts a container, not pushes an image.
4fill in blank
hard

Fill both blanks to tag a local Docker image before pushing it to ACR.

Azure
docker tag [1] [2]
Drag options to blanks, or click blank then click option'
Amyapp:latest
BmyRegistry.azurecr.io/myapp:v1
Cmyapp:v1
DmyRegistry.azurecr.io/myapp:latest
Attempts:
3 left
💡 Hint
Common Mistakes
Swapping the order of arguments causes tagging errors.
Using 'latest' tag inconsistently can confuse which image is pushed.
5fill in blank
hard

Fill all three blanks to build, tag, and push a Docker image to ACR manually.

Azure
docker [1] -t [2] . && docker [3] [2]
Drag options to blanks, or click blank then click option'
Abuild
BmyRegistry.azurecr.io/myapp:v2
Cpush
Drun
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'run' instead of 'push' uploads nothing.
Forgetting to tag the image before pushing causes errors.