apiVersion: cilium.io/v2
kind: CiliumNetworkPolicy
metadata:
  name: dns
spec:
  endpointSelector:
    matchLabels:
      app.kubernetes.io/name: bot
  egress:
    - toEndpoints:
        - matchLabels:
            io.kubernetes.pod.namespace: kube-system
            k8s-app: kube-dns
      toPorts:
        - ports:
            - port: "53"
              protocol: UDP
          rules:
            dns:
              - matchPattern: "*"
