services easy understanding

-what is a service?

service provides the same functionality to all the pods such as webservices, image processing . a service is responsible for exposing an interface to the pods .

-what is the types of service?

There are four types of service namely:

1.clusterIP – Exposes a service which is accessible only inside the cluster.

2.NodePort- Exposes a service to all the nodes in the cluster.

3.LoadBalancer- Exposes the service only to the cloud service provider.

4.ExternalName- Maps a service to a predefined external field.

-what is the use of service named with “Kubernetes” in default namespace?

The Kubernetes service in the default namespace is a service which forwards request to the Kubernetes master typically to the Kubernetes API server. so all the requests from the Kubernetes default service to the Endpoint IP.

-How services works?

services works based on the load balancer and it will get connected to the pods and inside the pods there are containers . and

it will match the IP address to the cluster.