Pushing images to the ACR instance
The ACR instance is ready, and we created Docker images in the previous chapter – now, let’s publish the images to this registry.
After you’ve logged in to Microsoft Azure (using az login
), to log in to the ACR instance, you can use az acr login
. Make sure to use the name you defined with the ACR instance:
az login az acr login -n <the name of your azure container registry>
This command needs to have Docker Desktop installed and running.
Note
Referencing the ACR instance using the Azure CLI, just the name of the registry is needed (such as codebreakertest
). The docker
and dotnet
commands support different registries, thus with these commands, the complete domain name is needed, such as codebreakertest.azurecr.io
.
Next, let’s build the images. With the game APIs, we created a Dockerfile in the previous chapter. With the Windows terminal, make sure to set the current directory to the ch06
folder and...