apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: allow-frontend-to-backend
namespace: backend
spec:
podSelector:
matchLabels:
app: backend
ingress:
- from:
- namespaceSelector:
matchLabels:
name: frontend
ports:
- port: 80
protocol: TCP
Allow Frontend To Backend
TrackKubernetes Learning Journey
Current SectionNetworking
Progress248 of 271