ื ืขืืืจ ื-IDE ืื ืืฆืืจ ืงืืืฅ ืืืฉ:
touch nginx-pod.yaml
ื ืืืืจ Pod ืจืืื (ืื ReplicaSet):
apiVersion: v1
kind: Pod
metadata:
name: solo-nginx
labels:
app: nginx
spec:
containers:
- name: nginx
image: nginx:1.27.0
ports:
- containerPort: 80
ืฉืืื ืื ๐
ื-label app: nginx ืืื ืืื ืฉืืืืืจ ื-ReplicaSet.
ื ืฉืืืจ ืืช ืืงืืืฅ.
ืืืจืืื ื ื ืฉืืืจ:
kubectl get pods --watch
ืืืืจืืื ื ื ืืกืฃ:
kubectl get rs --watch
ืืขืช ื ืืฆืืจ ืืช ื-Pod:
kubectl apply -f nginx-pod.yaml
ืืื ื ืจืื: