kind: NetworkPolicy
apiVersion: networking.k8s.io/v1
metadata:
  name: allow-by-ip
  namespace: "y"
spec:
  policyTypes:
    - Ingress
  podSelector:
    matchLabels:
      pod: c
  ingress:
    - from:
        - ipBlock:
            cidr: "0.0.0.0/24"