How to talk to Kubernetes CRD service within a pod in the same k8s cluster? How to talk to Kubernetes CRD service within a pod in the same k8s cluster? kubernetes kubernetes

How to talk to Kubernetes CRD service within a pod in the same k8s cluster?


It's clearly documented here. So basically, it creates a NodePort type of service. It also specifies that it could create an Ingress to access the UI. For example:

...status:  sparkApplicationId: spark-5f4ba921c85ff3f1cb04bef324f9154c9  applicationState:    state: COMPLETED  completionTime: 2018-02-20T23:33:55Z  driverInfo:    podName: spark-pi-83ba921c85ff3f1cb04bef324f9154c9-driver    webUIAddress: 35.192.234.248:31064    webUIPort: 31064    webUIServiceName: spark-pi-2402118027-ui-svc    webUIIngressName: spark-pi-ui-ingress    webUIIngressAddress: spark-pi.ingress.cluster.com

In this case, you could use 35.192.234.248:31064 to access your UI. Internally within the K8s cluster, you could use spark-pi-2402118027-ui-svc.<namespace>.svc.cluster.local or simply spark-pi-2402118027-ui-svc if you are within the same namespace.