Kubernetes CKA sample exam question 108 with answer

Question
List all the endpoints in kube-system namespace and save the output to /tmp/endpoints.txt

Answer
Endpoints usually represent IP address(es) of Pod(s) mapped with the services.
These are defined as separate resources in Kubernetes cluster. They can be called either using endpoints or ep with kubectl command:

kubectl get endpoints -n kube-system > /tmp/endpoints.txt
kubectl get ep -n kube-system > /tmp/endpoints.txt