

0 / 2 embers
0 / 3000 xp
click for more info
Complete a lesson to start your streak
click for more info
Difficulty: 3
click for more info
Not enough gems
Cost: 6 gems
1: Pods
incomplete
2: Ephemeral
incomplete
3: Unique IP Addresses
incomplete
This lesson's interactive features are locked, please to keep using them
Every Pod in a Kubernetes cluster has a unique internal-to-k8s IP address. By giving each Pod a unique IP, Kubernetes simplifies communication and service discovery within the cluster. Pods within the same Node or across different Nodes can easily communicate.
All the resources inside a k8s cluster are virtualized. So, the IP address of a Pod is not the same as the IP address of the Node it's running on. It's a virtual IP address that is only accessible from within the cluster.
Run this command to get a "wide" output of your pods:
kubectl get pods -o wide
It gives a few more columns of information, including the IP address of each Pod. Notice that each Pod has a unique IP address!
Next, run:
kubectl proxy
This will start a proxy server on your local machine, probably on 127.0.0.1:8001. Assuming that's the host, navigate to http://127.0.0.1:8001/api/v1/namespaces/default/pods in your browser. You should see a big nasty JSON blob that describes the pods that you have running.
Run and submit the CLI tests.
The tests will make sure that the proxy server is accessible and that it's returning information about the current Pods in your cluster.