Difficulty: Intermediate
Estimated Time: 15m

We are going to explore how DNS resolution in Kubernetes works. First we create a namespace, then we create a pod and expose it via service. Afterwards, a second pod is used to perform DNS queries against the Kubernetes DNS Resolver to get the IP address of the service.

Kubernetes DNS

Step 1 of 6

Step 1

First we need to start minikube to get the cluster running.

Start Minikube

This command may throw errors. Just wait some time and proceed with the example or run the command again.

minikube start

Check Cluster

kubectl get services

Set up Alias

alias k="kubectl"