

0 / 2 embers
0 / 3000 xp
click for more info
Complete a lesson to start your streak
click for more info
Difficulty: 3
click for more info
Not enough gems
Cost: 6 gems
1: The Control Plane
incomplete
2: Labels
incomplete
3: Dry Run
incomplete
4: Kubectl Explain
incomplete
5: Rollouts
incomplete
6: Rollbacks
incomplete
7: API Deployment
incomplete
8: Thrashing Pods
incomplete
This lesson's interactive features are locked, please to keep using them
Pod names change every time a pod is replaced, so Kubernetes doesn't really keep track of them by name. Instead, it uses labels.
A label is just a key/value pair attached to an object. When you ran kubectl create deployment synergychat-web, Kubernetes gave every new pod this label:
app: synergychat-webA selector is a query that matches labels. For example, the app=synergychat-web selector matches every pod with that label, no matter what the pod is named:
kubectl get pods -l app=synergychat-webLabels are important because they're how Kubernetes knows which pods belong to which deployments. The deployment continuously scans for pods matching its label selector, and those are the replicas it counts.
kubectl get pods --show-labelsYou'll see the app=synergychat-web label, plus a pod-template-hash label that Kubernetes uses to tell versions of a deployment apart.
Submit the shell checks.