Unexpected outbound connection destination
Event Information
Meaning
- This event indicates that a pod in the Kubernetes cluster is attempting to establish an outbound connection to a destination that is not expected based on the defined network policies.
- To investigate further, you can use the following kubectl command to identify the pod generating the unexpected outbound connection:
kubectl get pods --all-namespaces -o wide
- Once you have identified the pod, you can review its configuration and network policies to determine why it is attempting to connect to the unexpected destination:
kubectl describe pod <pod_name> -n <namespace>
Remediation
- Create a NetworkPolicy to restrict outbound connections:
- Apply the NetworkPolicy to the namespace where the affected pods are running:
- Verify that the NetworkPolicy is applied correctly: