Question 650
At Northstar finance, in an isolated training cluster during a scheduled maintenance rehearsal: A policy ./policies/invoice-api-peer.yaml is ready to permit Pod-to-Pod traffic only from trusted labels in namespace ledger. Work only within the stated target and verify before declaring success. Which Kubernetes behavior best explains the required change or diagnosis?
Explanation
Correct Answer
An ingress rule with a podSelector selects source Pods in its own namespace unless combined with other peer selectors. This explains the stated condition. The corresponding action is: Run kubectl -n ledger apply -f ./policies/invoice-api-peer.yaml after verifying podSelector rules match the source identity. The direct acceptance evidence is: Run positive and negative network connectivity tests from Pods with and without the trusted source label.
Incorrect Answers
This principle describes a separate cause: A ClusterIP Service provides stable in-cluster virtual addressing and directs traffic to selected ready Pod endpoints. The reported condition is governed by: An ingress rule with a podSelector selects source Pods in its own namespace unless combined with other peer selectors. The two mechanisms should not be conflated.
Ingress TLS termination relies on a controller and a referenced TLS Secret; updating a Service alone does not install certificates. That explanation applies to a different technical failure. Here the controlling principle is: An ingress rule with a podSelector selects source Pods in its own namespace unless combined with other peer selectors.
The offered statement is true for this other mechanism: A selecting NetworkPolicy with ingress isolation and no allow rules denies new ingress to selected Pods except protocol-specific policy behavior; it does not itself control egress. It does not explain the facts described here, which follow from: An ingress rule with a podSelector selects source Pods in its own namespace unless combined with other peer selectors.