Docker

How-to: Push an image from docker registry to Azure Container Registry

0 min read

With the Docker registry download limits, one way to circumvent those limits is to use your own registry, such as Azure Container Registry or for short ACR. This post will show you how to save an image from a Docker registry to an Azure Container Registry.

How-To

1. Login to Azure Container Registry

Pre-requirements: have az cli installed

To login to ACR, in a command shell, type az acr login

2. Pull the image from Docker registry

In my case I wanted to push the image mcr.microsoft.com/azure-storage/azurite to my ACR.

3. Tag the image

To upload to ACR, you need to tag the image with the proper tag: name.azurecr.io/repostority/imagename:tag

Latest can be daunting. So I also tagged the image with the “real” latest version number. As of this post, it is 3.9.0.

4. Push the image to Azure Container Registry

5. Delete the local images (Optional)

If you want you can delete the images

Voilà!