<p>I am running Harbor Registry on my cluster and I have no problem pushing and pulling the images from outside of the cluster.</p>

<p>Now I'd like to be able to create a pod from that registry.
Something like this:</p>

<pre><code>.
kubectl run -i --tty --rm debug --image=harbor.harbor.svc.cluster.local/test/alpine:latest --restart=Never -- sh

.
</code></pre>

<p>Is this possible?</p>

<p><strong>Update</strong></p>

<p>If I try to access the registry by its service name <code>harbor.harbor.svc.cluster.local</code> it doesn't work because the host name is not found.</p>

<p>How can I reference my image? </p>

<p>As @Rajesh mentioned in comment, you need to create <a href="https://kubernetes.io/docs/concepts/services-networking/service/#nodeport" rel="nofollow noreferrer">NodePort</a> type service if you are on same subnet with your nodes or if you are using some cloud for your cluster such as AWS, GKE, also you can create <a href="https://kubernetes.io/docs/concepts/services-networking/service/#loadbalancer" rel="nofollow noreferrer">LoadBalancer</a> type service and access through External Loadbalancer to your registry. </p>
