Creating a Service and Discovering DNS Names in Kubernetes
Create an nginx deployment, and verify it was successful
kubectl run nginx --image=nginx

Create a service, and verify the service was successful


Create a pod that will allow you to query DNS, and verify it’s been created

Perform a DNS query to the service

Record the DNS name

PreviousDeploying a Pod to a Node with a Label in KubernetesNextScheduling Pods with Taints and Tolerations in Kubernetes
Last updated