apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
  name: queue-network-policy
spec:
  podSelector:
    matchLabels:
      component: queue
  policyTypes:
    - Ingress
    - Egress
  ingress:
    - from:
        - podSelector:
            matchExpressions:
              - key: component
                operator: In
                values:
                  - api
                  - horizon
                  - scheduler
      ports:
        - port: 6379
