What is an 'endpoint' in Kubernetes?

Chris picture Chris · Oct 17, 2018 · Viewed 28.5k times · Source

I am new to Kubernetes and started reading through the documentation. There often the term 'endpoint' is used but the documentation lacks an explicit definition.

What is an 'endpoint' in terms of Kubernetes? Where is it located?

I could image the 'endpoint' is some kind of access point for an individual 'node' but that's just a guess.

Answer

Michael Hausenblas picture Michael Hausenblas · Oct 17, 2018

While you're correct that in the glossary there's indeed no entry for endpoint, it is a well defined Kubernetes network concept or abstraction. Since it's of secondary nature, you'd usually not directly manipulate it. There's a core resource Endpoint defined and it's also supported on the command line:

$ kubectl get ep
NAME         ENDPOINTS            AGE
kubernetes   192.168.64.13:8443   10d

And there you see what it effectively is: an IP address and a port. Usually, you'd let a service manage endpoints (one EP per pod the service routes traffic to) but you can also manually manage them if you have a use case that requires it.