﻿kind: NetworkPolicy
apiVersion: networking.k8s.io/v1
metadata:
  name: db-accessable
  namespace: default
spec:
  podSelector:
    matchLabels:
      run: db
  ingress:
  - from:
    - podSelector:
        matchLabels:
          db-accessable: "true"
    ports:
    - protocol: TCP
      port: 80
