Difficulty: Introduction
Estimated Time: 20 minutes

Container Registries on Kubernetes

As a developer of container and Kubernetes solutions there is often a need to publish containers to a private registry. When we are prototyping or testing it's handy to setup a local registry that just you or a small group can leverage. Kubernetes is ideal for hosting this solution.

The Registry is a stateless, highly scalable server side application that stores and lets you distribute container images. The Registry is open-source, under the permissive Apache license.

To learn how the registry works, you will build, push and pull a real application with the registry. The application is a Breast Cancer Mitosis Detector provided by IBM. IBM has over 40 open source projects covering various deep learning models.

Key Features

  • Follows the Docker Registry HTTP API V2
  • Accepts pushed containers
  • Fulfills container requests
  • Images persisted to backing PersistentVolume
  • Easily hosted on Kubernetes

You will learn how:

  • to install a private container registry on Kubernetes
  • to install a web interface to reveal the contents of the registry.

Lessons Learned

Generally there are three ways to interact with container registries.

  1. Public registries like DockerHub, Quay.io, gcr.io
  2. Private team registries that are within you organization, often hosted by your cloud provider
  3. Private registries that you or your team may be using on a local or private Kubernetes cluster or namespace.

This tutorial gives you a leg up for leveraging personal and local registries. This is ideal when you are prototyping or rapidly developing and testing a solution locally. Knowing how to quickly setup and use a private container is another technique you can pull out of your Kubernetes toolbox.

With these steps you have learned:

  • how to install a private container on Kubernetes,
  • how to install web interface to list the registry contents



Lost friend and father, Bill Becker. Male Breast Cancer Awareness Week is the third week of October.

No Fluff Just Stuff

For a deeper understanding of these topics and more join me, Jonathan Johnson, for a transcendent experience on the No Fluff Just Stuff Software Symposium Tour.


Step 1 of 6

Your Kubernetes Cluster

For this scenario, Katacoda has just started a fresh Kubernetes cluster for you. Verify it's ready for your use.

kubectl version --short && \ kubectl get componentstatus && \ kubectl get nodes && \ kubectl cluster-info

The Helm package manager used for installing applications on Kubernetes is also available.

helm version --short

Kubernetes Dashboard

You can control the cluster with the kubectl CLI tool or through the Kubernetes Dashboard. Because the dashboard can be accessed publicly, it is protected and requires the secret access token to sign in. Copy the token from this secret.

export TOKEN=$(kubectl describe secret $(kubectl get secret | awk '/^dashboard-token-/{print $1}') | awk '$1=="token:"{print $2}') && echo -e "\n--- Copy and paste this token for dashboard access --\n$TOKEN\n---"

To access the dashboard, click on the Kubernetes Dashboard tab above the command line or from this link: https://[[HOST_SUBDOMAIN]]-30000-[[KATACODA_HOST]].environments.katacoda.com/. At the sign in prompt select Token and paste in the token, you copied a moment ago.

For Kubernetes clusters exposed to the public, always lock administration access including access to the dashboard.

Kubernetes Dashboard
Cancer Detector