Completed upto lesson 30

This commit is contained in:
Mosiur Rahman
2026-08-23 15:53:35 +06:00
parent 8e43c00cd6
commit f1b693a147
6 changed files with 21754 additions and 1 deletions

35
lab/lesson-29-answer.yaml Normal file
View File

@@ -0,0 +1,35 @@
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: test-network-policy
namespace: storefront
spec:
podSelector:
matchLabels:
app: frontend
policyTypes:
- Egress
egress:
- to:
- namespaceSelector:
matchLabels:
kubernetes.io/metadata.name: payments-mesh
podSelector:
matchLabels:
app: payments-api
ports:
- protocol: TCP
port: 8080
- to:
- namespaceSelector:
matchLabels:
kubernetes.io/metadata.name: kube-system
podSelector:
matchLabels:
k8s-app: kube-dns
ports:
- port: 53
protocol: TCP
- port: 53
protocol: UDP