Completed upto lesson 28

This commit is contained in:
Mosiur Rahman
2026-08-23 15:29:06 +06:00
parent fb86f0b60a
commit 8e43c00cd6
104 changed files with 1888 additions and 0 deletions

View File

6
answers/lesson-3.yaml Normal file
View File

@@ -0,0 +1,6 @@
#Timed Task
# command
kubeclt create role reporter-role --namespace=cks-rbac --verbs="get,list" --resources="configmaps" --dry-run=client -o yaml
kubectl create rolebinding reporter-rolebinding --namespace=cks-rbac --serviceaccount=cks-rbac:report-reader --role=reporter-role --dry-run=client -o yaml

View File

@@ -0,0 +1,29 @@
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: app-control
namespace: database
spec:
policyTypes:
- Ingress
- Egress
podSelector:
matchLabels:
app: db
ingress:
- from:
- nameSpaceSelector:
matchLabels:
kubernetes.io/metadata: payments
podSelector:
matchLabels:
app: payments
ports:
- port: 5432
protocol: TCP
egress:
- ports:
- protocol: TCP
port: 53
- protocol: UDP
port: 53