Azure

Install Docker on a Azure Linux VM, upload a docker image to Azure Container Registry and Deploy a Azure Container Instance Part 5 – Push a docker image to Azure Registry

Let’s push our hello world to Azure Registry. You can check it out here.

First we must install the Azure CLI on our linux vm. Run the installer script.

curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash

Next sign in to Azure on your Linux vm.

az login

Next sign in to the azure container registry, Don’t include the ‘azurecr.io’ domain suffix.

az acr login --name 

Next tag the hello world image with your container registry name. The login server name is in the format <registry-name>.azurecr.io (all lowercase), for example, mycontainerregistry.azurecr.io.

docker tag hello-world /hello-azure-world:v1

Perfect! Now with the tag let’s push to our registry!

docker push /hello-azure-world:v1

Let’s quickly jump over to the Azure portal and check our uploaded image.

You can also check from az cli with

az acr repository list -n registryname

And finally you can now download your own hello world container from your very own Azure Container Registry!

docker run /hello-azure-world:v1

There you go! You just uploaded your very own Docker image to an Azure Container Registry and deployed it.

Now in the last post we will create an Docker instance from our hello world

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: