Custom Search

Saturday, December 7, 2019

Kubernetes Access Service located in another Namespace

sajuptpm@cloudshell:~$
sajuptpm@cloudshell:~$
sajuptpm@cloudshell:~$ kubectl get services
NAME                                 TYPE        CLUSTER-IP      EXTERNAL-IP   PORT(S)          AGE
jenkins-1-jenkins-agents-connector   ClusterIP   10.15.241.134           50000/TCP        192d
jenkins-1-jenkins-ui                 NodePort    10.15.248.131           8080:32551/TCP   192d
kubernetes                           ClusterIP   10.15.240.1             443/TCP          192d
sajuptpm@cloudshell:~$
sajuptpm@cloudshell:~$
sajuptpm@cloudshell:~$
sajuptpm@cloudshell:~$ kubectl get services -n kube-system
NAME                   TYPE        CLUSTER-IP      EXTERNAL-IP   PORT(S)         AGE
default-http-backend   NodePort    10.15.254.200           80:32596/TCP    192d
heapster               ClusterIP   10.15.254.154           80/TCP          192d
kube-dns               ClusterIP   10.15.240.10            53/UDP,53/TCP   192d
metrics-server         ClusterIP   10.15.249.48            443/TCP         192d
tiller-deploy          ClusterIP   10.15.247.88            44134/TCP       151d
sajuptpm@cloudshell:~$
sajuptpm@cloudshell:~$

kubectl exec -it jenkins-1-jenkins-deployment-5fc5855c54-dswcq -- /bin/sh

curl http://heapster.kube-system.svc.cluster.local

curl http://jenkins-1-jenkins-ui.default.svc.cluster.local:8080
curl http://jenkins-1-jenkins-ui:8080

No comments:

Post a Comment