I've deployed a registry service into a namespace registry
:
$ kubectl get service -n registry
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
registry-docker-registry ClusterIP 10.43.119.11 <none> 5000/TCP 18h
this is my skaffold.yaml
:
apiVersion: skaffold/v2beta1
kind: Config
metadata:
name: spring-boot-slab
build:
artifacts:
- image: skaffold-covid-backend
kaniko:
dockerfile: Dockerfile-multistage
cache: {}
cluster: {}
deploy:
kubectl:
manifests:
- k8s/*
Everything works fine, up to when kaniko is trying to push the image to above registry:
Get "http://registry-docker-registry.registry.svc.cluster.local:5000/v2/": dial tcp: lookup registry-docker-registry.registry.svc.cluster.local on 127.0.0.53:53: no such host
Any ideas about how to get access to this registry deployed inside the same kubernetes?
I've tried to get access to the registry from another pod:
$ kubectl exec -ti graylog-1 -- curl registry-docker-registry.registry:5000/v2/_catalog
{"repositories":["skaffold-covid-backend","skaffold-covid-backend/cache"]}
As you can see, it's able to get access to registry.