If I have to integrate an external service, I have 3 options to make it accessible from Kubernetes cluster.
- Use ExternalName in Kubernetes Service object
- Use ExternalIP in Kubernetes Service Object
- Set up an Endpoint object and map the endpoint to a Service Object
Third one is the recommended as per best practices on Kuberenetes. In case if there are multiple nodes mapped to a service, Endpoint Object provides an option to list multiple IP addresses. But unfortunately Endpoint Object does not accept hostnames.
So in my scenario, I need to access MKS cluster from a service deployed in AWS-EKS cluster. If I consider MKS as an external service, I have only one option(setup an endpoint and a service), since my MKS cluster has multiple nodes. But unfortunately EndPoint schema access only IP addresses. And I am assuming the IP addresses under the hood of MKS cluster are elastic IPs, and I am not supposed to use those for my configuration.
My questions:
Do I need to consider MKS as an external service, when I try to deploy my application in AES-EKS service? If answer is yes, What are the options available for me to resolve this scenario?
In case, MKS is also deployed on top of EKS, by setting up security groups properly in between VPC's along with VPC peering, can I access MSK from services deployed on EKS?