Local Registry
The local registry gives kinder clusters a private container registry at localhost:5001. Push images from your host and pull them directly in pods — no external registry or image loading required.
kinder installs the registry:2 image.
What gets installed
Section titled “What gets installed”| Resource | Namespace / Location | Purpose |
|---|---|---|
kind-registry container | Docker/Podman host | Runs the registry on port 5001 |
containerd certs.d config | All cluster nodes | Routes localhost:5001 to the registry container |
local-registry-hosting ConfigMap | kube-public | Dev tool discovery (Tilt, Skaffold, etc.) |
How it works
Section titled “How it works”The registry runs as a standalone container on the same Docker/Podman network as the cluster nodes. Each node is configured with a containerd hosts.toml entry that resolves localhost:5001 to the registry container. This means both the host machine and pods inside the cluster can push and pull from the same address.
The registry container persists across cluster recreations — cached images survive kinder delete cluster and kinder create cluster.
How to use
Section titled “How to use”Push an image from your host:
docker build -t localhost:5001/myapp:latest .docker push localhost:5001/myapp:latestReference it in a pod:
apiVersion: v1kind: Podmetadata: name: myappspec: containers: - name: myapp image: localhost:5001/myapp:latestHow to verify
Section titled “How to verify”After creating a cluster, confirm the registry container is running:
docker ps --filter name=kind-registryExpected output:
CONTAINER ID IMAGE ... PORTS NAMESabc123 registry:2 ... 0.0.0.0:5001->5000/tcp kind-registryVerify the ConfigMap exists for dev tool discovery:
kubectl get configmap local-registry-hosting -n kube-public -o yamlTest a full push-and-pull cycle:
docker pull nginx:alpinedocker tag nginx:alpine localhost:5001/nginx:testdocker push localhost:5001/nginx:testkubectl run regtest --image=localhost:5001/nginx:testkubectl get pod regtestConfiguration
Section titled “Configuration”The local registry is controlled by the addons.localRegistry field in your cluster config:
apiVersion: kind.x-k8s.io/v1alpha4kind: Clusteraddons: localRegistry: true # defaultSee the Configuration Reference for all available addon fields.
How to disable
Section titled “How to disable”To create a cluster without the local registry, set localRegistry: false:
apiVersion: kind.x-k8s.io/v1alpha4kind: Clusteraddons: localRegistry: falseDev tool integration
Section titled “Dev tool integration”The local-registry-hosting ConfigMap in kube-public follows KEP-1755, which allows tools like Tilt and Skaffold to auto-discover the registry endpoint. No additional configuration is needed in these tools.
Multi-image workflow
Section titled “Multi-image workflow”Build and push multiple images, then verify they are all available in the registry:
docker build -t localhost:5001/frontend:v1 ./frontenddocker push localhost:5001/frontend:v1
docker build -t localhost:5001/backend:v1 ./backenddocker push localhost:5001/backend:v1Verify both images are registered:
curl http://localhost:5001/v2/_catalogExpected output:
{"repositories":["backend","frontend"]}Reference both images in a Deployment:
apiVersion: apps/v1kind: Deploymentmetadata: name: myappspec: replicas: 1 selector: matchLabels: app: myapp template: metadata: labels: app: myapp spec: containers: - name: frontend image: localhost:5001/frontend:v1 - name: backend image: localhost:5001/backend:v1Cleaning up images
Section titled “Cleaning up images”The simplest cleanup approach is to re-push with the same tag to overwrite an existing image:
docker build -t localhost:5001/myapp:latest .docker push localhost:5001/myapp:latest # overwrites the previous imageTo list all tags for a specific image:
curl http://localhost:5001/v2/myapp/tags/listNote that registry:2 does not garbage-collect by default — disk space is reclaimed only when the registry container is recreated. For a fresh start:
docker rm -f kind-registryThe registry will be recreated on the next kinder create cluster.
Troubleshooting
Section titled “Troubleshooting”ImagePullBackOff from localhost:5001
Section titled “ImagePullBackOff from localhost:5001”Symptom: kubectl describe pod shows Failed to pull image "localhost:5001/myapp:latest" with ImagePullBackOff.
Cause: The kind-registry container is not running — it may have been stopped or removed.
Fix: Check whether the registry is running:
docker ps --filter name=kind-registryIf the container exists but is stopped, start it:
docker start kind-registryIf it was removed, the simplest fix is to recreate the cluster:
kinder create clusterThis recreates the registry container automatically.