Testdriving the Azure Container Registry Service with Rancher

Introduction

A few weeks ago there was an announcement that the Azure Container Registry has went into public preview. That is great to hear! So let’s test drive it today… We’re going to set up the registry in Azure. Push a container image into it. And pull/run it via rancher towards our cluster. (To do this, I basically followed a lot of the following guide.

 

Setting up the Azure Container Registry (ACR)

So start by searching for the “Container Registry” in the marketplace ;

2016-12-07-13_40_08-everything-microsoft-azure

And enter the needed credentials. Be aware that, at this time, the location is limited to three regions in the US.

2016-12-07-13_40_26-container-registry-microsoft-azure

Let it crunch for a while, and you’ll have yourself a Container Registry!

2016-12-07-13_01_49-access-key-microsoft-azure

(Sidenote ; nice try using my password, I’ve regenerated that one!) 😀

 

Pushing an image into ACR

Next up, we’ll build a docker image…

2016-12-07-13_03_41-rootkvaesjumpsuit__docker

Once built, we do a login towards our registry ;

2016-12-07-13_03_23-rootkvaesjumpsuit__docker

Tag the image with a name we could remember…

2016-12-07-13_05_27-rootkvaesjumpsuit__docker

And then push it to the registry!

2016-12-07-13_05_50-rootkvaesjumpsuit__docker

Now if we would go and look at the storage account related to the registry ;

2016-12-07-13_10_39-program-manager

Here we can see that all layers are stored nicely in a structured manner as blobs.

 

Integrating ACR with Rancher

Pushing images into a registry is one thing, pulling & running them is where the business sees value! So let’s integrate the registry with our Rancher environment.

Browse to “Infrastructure” and then “Registries” ;
2016-12-07-13_25_20-rancher

Now press the “Add Registry”-button …

2016-12-07-13_25_36-rancher

And enter all the information about the registry. Do note that the email doesn’t matter, all other parameters are the once your can see in the Azure Portal.

2016-12-07-13_31_17-rancher

Once finished, the registry will appear in your list…

2016-12-07-13_31_30-program-manager

And you can start using it for services. So let’s do that, shall we?

2016-12-07-13_32_12-rancher

Looking great…

2016-12-07-13_32_26-program-manager

and done! The system has been started by using a container image from our Azure Container Registry.

2016-12-07-13_33_21-rancher

 

Is it expensive?

The Azure Container Registry Services is free! However… you’ll pay for the storage you are consuming on your storage account.  So with the current market rate, that would be about 4 euro cents per GB per month. That isn’t a bad price I would recon?

 

So how does it compare to docker hub / quay, and so on?

As a registry, it’s the same functionality. I would have hoped the ASR would provide a hybrid capability, though that may come in the future. Though, docker hub has a very easy CI integration (“automated builds”). Where ASR will rely on you leveraging your existing CI-tool (like Visual Studio Team Services, Jenkins, Travis, etc) to do so.

 

Anyhow, enjoy playing with ASR!

Advertisements

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 )

Twitter picture

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

Facebook photo

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

Google+ photo

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

Connecting to %s