k3s-cluster/cluster/apps/media/network_policy.yaml

17 lines
365 B
YAML
Raw Normal View History

2023-04-04 02:01:25 -04:00
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: deny-most-allow-some
namespace: media
spec:
# Apply to all pods in this namespace
2023-04-04 02:03:23 -04:00
podSelector: {}
2023-04-04 02:01:25 -04:00
ingress:
- from:
# Allow all pods in this namespace
- podSelector: {}
# Allow all pods with this label
2023-04-04 02:21:11 -04:00
# - podSelector:
# matchLabels:
# needsMedia: 'yes'