

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: Welcome to 'Learn Kubernetes'
incomplete
2: Deployments
incomplete
3: Pods
incomplete
4: Deployment and Pod Review
incomplete
5: What Is Kubernetes?
incomplete
6: Ephemeral
incomplete
7: Desired State
incomplete
8: Unique IP Addresses
incomplete
9: Describe
incomplete
10: Replica Sets
incomplete
11: YAML Config
incomplete
Back
ctrl+,
Next
ctrl+.
This lesson's interactive features are locked, please to keep using them
When you delete a pod managed by a deployment, Kubernetes creates a new pod in its place as soon as it can. It's kinda like chopping heads off a hydra.
That's because the desired state described in our deployment says we want 20 pods running at all times. If we delete one, Kubernetes' controllers detect that the current state doesn't match the desired state, and a replacement is created to make them match again.
Twenty copies of a chat app with zero users is... a bit much. Money for hardware doesn't grow on trees. Change the desired state to 2 pods by editing the deployment directly.
spec:
...
replicas: 2
...Submit the shell checks.