Accessing Kubernetes API

In this lesson, we will explore the Kubernetes API and the process to access it.

The API

Every interaction with Kubernetes goes through its API and needs to be authorized. That communication can be initiated through a user or a service account. All Kubernetes objects currently running inside our cluster are interacting with the API through service accounts. We won’t go deep into those. Instead, we’ll concentrate on the authorization of human users.

ℹ️ All the commands from this chapter are available in the 12-auth.sh Gist.

Checking out the Port

Typically, the Kubernetes API is served on a secured port. Our Minikube cluster is no exception. We can check the port from the kubectl config.

Get hands-on with 1200+ tech skills courses.