CI executor pods (label foxhunt-ci) were selected by allow-monitoring-scrape (which uses matchExpressions In [foxhunt, foxhunt-ci]) making them policy-controlled, but allow-dns only selected foxhunt pods via matchLabels. This blocked DNS resolution → git clone failure in deploy jobs. - Update allow-dns podSelector to matchExpressions In [foxhunt, foxhunt-ci] - Add ci-egress policy granting broad egress for ephemeral CI pods Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
27 lines
630 B
YAML
27 lines
630 B
YAML
# Allow all foxhunt + CI pods to reach CoreDNS (kube-system) for name resolution.
|
|
apiVersion: networking.k8s.io/v1
|
|
kind: NetworkPolicy
|
|
metadata:
|
|
name: allow-dns
|
|
namespace: foxhunt
|
|
labels:
|
|
app.kubernetes.io/part-of: foxhunt
|
|
spec:
|
|
podSelector:
|
|
matchExpressions:
|
|
- key: app.kubernetes.io/part-of
|
|
operator: In
|
|
values: [foxhunt, foxhunt-ci]
|
|
policyTypes:
|
|
- Egress
|
|
egress:
|
|
- to:
|
|
- namespaceSelector:
|
|
matchLabels:
|
|
kubernetes.io/metadata.name: kube-system
|
|
ports:
|
|
- protocol: UDP
|
|
port: 53
|
|
- protocol: TCP
|
|
port: 53
|