gogs-np.yaml 308 B

123456789101112131415161718
  1. apiVersion: networking.k8s.io/v1
  2. kind: NetworkPolicy
  3. metadata:
  4. name: gogs-to-mariadb
  5. spec:
  6. podSelector:
  7. matchLabels:
  8. name: gogs
  9. policyTypes:
  10. - Egress
  11. egress:
  12. - to:
  13. - namespaceSelector:
  14. matchLabels:
  15. name: mariadb
  16. ports:
  17. - protocol: TCP
  18. port: 3306