kind: NetworkPolicy
apiVersion: networking.k8s.io/v1
metadata:
  name: frontend-policy
  namespace: web
spec:
  podSelector:
    matchLabels:
      role: frontend
  ingress:
  - from:
    - namespaceSelector:
        matchLabels:
          role: frontend  
      podSelector:
        matchLabels:
          role: frontend
  # egress: 
  # - to:
  #   - namespaceSelector:
  #       matchLabels:
  #         role: backend
      