What is Kubernetes mainly used for?
Options
- Writing Python code that is going to run inside containers
- Orchestrating containers across machines: scheduling, scaling, restarts (Correct option)
- Replacing Git as the version control system for the code
- Designing the databases that are used by the application
Answer
Orchestrating containers across many machines: scheduling, scaling, restarting failed ones and routing traffic
Why
Running one container is easy. Running hundreds across many servers, keeping them alive, updating them without downtime and connecting them is hard.
Kubernetes (K8s) does this automatically: you describe the desired state ('3 copies of my API, version 2.1') and it keeps reality matching it.
Managed versions: EKS (AWS), GKE (Google), AKS (Azure).
Remember
Kubernetes = automatic manager for many containers.