KubeLinter

KubeLinter

Community Analyzer

Misconfigured NetworkPolicyPeer podSelectors KUBELIN-W1007

Anti-pattern
Major

Indicates when NetworkPolicyPeer in Egress/Ingress rules -in the Spec of NetworkPolicy- do not have any associated deployments. Applied on peer specified with podSelectors only.

Remediation

Confirm that your NetworkPolicy's Ingress/Egress peer's podselector correctly matches the labels on one of your deployments.