Correct Answer: A Service with ClusterIP set to 'None'
Setting ClusterIP to 'None' creates a Headless Service. This allows direct DNS resolution to the individual Pod IPs, which is required for StatefulSets to maintain network identity...
Correct Answer
A Service with ClusterIP set to 'None'
Why This Answer Is Correct
Setting ClusterIP to 'None' creates a Headless Service. This allows direct DNS resolution to the individual Pod IPs, which is required for StatefulSets to maintain network identity.
This question evaluates your knowledge of Kubernetes Services β a core concept tested in cloud certification exams. Understanding Kubernetes Services is essential for designing scalable, secure, and cost-effective cloud architectures. Mastery of this topic will help you answer scenario-based questions confidently on exam day.
When defining a Kubernetes Service, which type ensures the service is exposed on each nodeβs IP at a static port?
Your organization wants to expose a web application running on Kubernetes to external traffic. You need a solution that assigns a static public IP address and routes traffic across all healthy nodes. Which Kubernetes Service type is most appropriate?
A frontend deployment needs to communicate with a backend API deployment named 'payment-api' within the same namespace. How should the frontend securely and dynamically resolve the backend's address?
You need to integrate a legacy database hosted outside of your Kubernetes cluster into your microservices. You want the microservices to address the database using a standard Kubernetes DNS name (e.g., 'legacy-db') to easily swap it later. Which Service type should you use?