How much ACR (Azure Container Registry) costs?

Well, believe it or not, this Azure service has no free subscription. The ‘cheapest’ one is about $0.252/day with total of 10 GiB of storage and 2 Web hooks. Unfortunatelly, with no support for Geo replication.

As pricing can change over the time, this site should give you the most up-to-date details: https://azure.microsoft.com/en-us/pricing/details/container-registry/

_BASICSTANDARDPREMIUM
Price per day$0.252$1.008$2.520
Included storage (GiB)10100500
Premium offers enhanced throughput for docker pulls across multiple, concurrent nodes
Total web hooks210500
Geo ReplicationNot SupportedNot SupportedSupported
$2.520 per replicated region
Azure Container Registery pricing

Do I like ACR?

Yes and no …

For a big projects in size, where the biggest proportion of the solution services is getting provisioned in Azure – Yes, definetely. The level of convinience of having ‘everything’ (source code, tool-set, hosting environment, …) in one place plays a big role in here. The assumption is that if Devs/DevOps are happy with tool-set within the same platform, the overall progress on the project should be faster as there is no need for an extra work for system integration and shaping diametrically different skill set (theory but works in many cases).

And for the projects hungry for disk space and tight to budget – No. There are cheaper alternatives on the market, for example Docker.com (with one private repository in Free plan – whoop, whoop!). Pricing starts as low as USD $5/month (with annual plan) which is insanely CHEAP! So if Azure is not your dime in solution, Docker.com wold be my choice to pick.

More details about Docker pricing (and most updated) can be found here: https://www.docker.com/pricing

Docker pricing and subscriptions
Docker pricing and subscriptions

Overall rating of this technology

5/5 Rambos

Committing and Pushing Docker image changes to Azure Container Registry

Docker image

If you made it this far, then you must know something about the Docker (Containerization). That is great because this post is not about what Docker really is but how to work with image revisions in conjunction with the Azure Container Registry (aka repo).

I am assuming you have your own repository in Azure created already and know the basic commands of how to spin up the container (or leave the comments below).

Also that a Docker desktop is installed on your PC and has docker image ready to be used for this exercise.

User story

You as a developer want to create a starting (based) image out of the running container on your localhost (image type regardless of this exercise) for your co-workers. Image is going to be parked in ACR for easy access. The initial version is going to have a tag ‘v1’.

Steps to follow

1. Download MS Azure Command Prompt, the latest version can be found here or just use google search


2. Validate that installation has been succesful by starting the MS Azure Promp and run

az --version
If you see this, then you did well!


3. Log in to Azure by using this command below (you should be redirected onto the browser app with portal.azure.com as URL. Now, use your user credentials and wait for callback redirect back to the terminal (MS ACP)

az acr login --name <your ACR name> 

Example:

az acr login --name webcommerce22


4. Commit the latest changes on the top of running docker container (docker desktop) with tag v1 (this operation creates a new image). Remember that only these characters are allowed in naming ‘a-z0-9-_.’

docker commit <docker container hash id> <repository URL>[/<new image name>][:<tag name>]

Example:

docker commit 2cbbb6f54f4b webcommerce22.azurecr.io/web-api-pricing:v1
The created new image out of running container


5. Push the changes to ACR

docker push <repository URL>[/<image name>][:<tag id>]

Example:

docker push webcommerce22.azurecr.io/web-api-pricing:v1
Pushing image to Azure Container Registery
New container repository is created with v1 image in it


And here you are. Great way how to keep your changes over the container image revisioned.

For more details about the docker commands, I can recommend to follow this URL https://docs.docker.com/engine/reference/commandline/docker/

Overall feature rating

5/5 Rambo rating