Private Registry with Kubernetes in Rancher


If you are running Rancher with no internet access or Rancher does not have access to DockerHub (i.e. docker.io) and Google Container Registry (i.e. gcr.io), then the pod infra container image and Kubernetes add-ons will not be installed. You will need to configure Kubernetes to point to a private registry for installing the Kubernetes add-ons and the pod infra container image.

Private Registry Requirements

Rancher expects the private registry to mirror DockerHub (i.e docker.io) and Google Container Registry (i.e. gcr.io).

Pod Infra Container Image

When configuring Kubernetes, Rancher uses an image whose network/ipc namespaces will be used in each pod.

# Located as a default value in the k8s templates
Image: gcr.io/google_containers/pause-amd64:3.0
Kubernetes Add-Ons

The namespace/name:tag is expected to be consistent the images in the Rancher add-on templates.

The images below are the list of add-ons that are currently supported, you will need to check the Github repo for exact version and copy the exact version for each image.

Images for Helm
# Located in the helm/tiller-deploy.yaml
image: <$PRIVATE_REGISTRY>/kubernetes-helm/tiller:<VERSION>
Images for Dashboard
# Located in the dashboard/dashboard-controller.yaml
image: <$PRIVATE_REGISTRY>/google_containers/kubernetes-dashboard-amd64:<VERSION>
Images for Heapster
# Located in the heapster/heapster-controller.yaml
image: <$PRIVATE_REGISTRY>/google_containers/heapster:<VERSION>

# Located in the heapster/influx-grafana-controller.yaml
image: <$PRIVATE_REGISTRY>/kubernetes/heapster_influxdb:<VERSION>
image: <$PRIVATE_REGISTRY>/google_containers/heapster_grafana:<VERSION>
Edit this page