Skip to content

Commit

Permalink
connectivity: include k8s-app=coredns matchLabels
Browse files Browse the repository at this point in the history
A few policy tests explicitly allow egress to CoreDNS, using an ancient
label selector that can't necessarily be relied on. Interestingly, some
of the tests (such as client-egress-to-fqdns-one-one-one-one), already had
network policies that included a label selector for k8s-app=coredns
in addition to k8s-app=kube-dns, but not all.

Signed-off-by: Sam Day <[email protected]>
  • Loading branch information
samcday committed Feb 1, 2022
1 parent 79e9ae2 commit 4cc839f
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
3 changes: 3 additions & 0 deletions connectivity/manifests/client-egress-only-dns.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,6 @@ spec:
- matchLabels:
k8s:io.kubernetes.pod.namespace: kube-system
k8s:k8s-app: kube-dns
- matchLabels:
k8s:io.kubernetes.pod.namespace: kube-system
k8s:k8s-app: coredns
3 changes: 3 additions & 0 deletions connectivity/manifests/client-egress-to-echo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,6 @@ spec:
- matchLabels:
k8s:io.kubernetes.pod.namespace: kube-system
k8s:k8s-app: kube-dns
- matchLabels:
k8s:io.kubernetes.pod.namespace: kube-system
k8s:k8s-app: coredns
3 changes: 3 additions & 0 deletions connectivity/manifests/client-egress-to-entities-world.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ spec:
- matchLabels:
k8s:io.kubernetes.pod.namespace: kube-system
k8s-app: kube-dns
- matchLabels:
k8s:io.kubernetes.pod.namespace: kube-system
k8s:k8s-app: coredns
toPorts:
- ports:
- port: "53"
Expand Down

0 comments on commit 4cc839f

Please sign in to comment.