---
kind: NetworkPolicy
apiVersion: networking.k8s.io/v1
metadata:
  name: default-deny
spec:
  policyTypes:
  - Ingress
  - Egress
  podSelector: {}
  egress:
    - to:
      - namespaceSelector:
          matchLabels:
            k8s-namespace: kube-system
        podSelector:
          matchExpressions:
          - key: k8s-app
            operator: In
            values: ["kube-dns","node-local-dns"]
      ports:
      - protocol: TCP
        port: 53
      - protocol: UDP
        port: 53
