Pod, Service, and Cross-Namespace DNS Resolution
Scenario
Create a Pod named orbit-api in the blackhole namespace using the image nginx:alpine. Apply the label project=orbit-api and mount the existing ConfigMap orbit-index as a volume at /usr/share/nginx/html so nginx serves the provided index.html.
Expose the Pod by creating a ClusterIP Service named orbit-svc in the blackhole namespace. Configure the Service to listen on port 4444 and forward traffic to container port 80, using the label selector project=orbit-api.
From the default namespace, create a temporary Pod named client-pod using the busybox image. Use this Pod to make an HTTP request to the Service using its DNS name:
http://orbit-svc.blackhole.svc.cluster.local:4444
Save the output of the request on dev-machine:
/home/laborant/orbit-test.html
Ensure the saved file contains the response served by nginx, confirming successful service exposure and cross-namespace DNS resolution.