现在有三种部署方式,传统物理机部署、虚拟机部署、容器化部署。
我们现在所使用的云上服务器一般都是虚拟化出来的,硬件资源独立,操作系统等软件资源亦独立。
容器化的好处是更轻量,复用下层的操作系统,相当于是又抽象了一层。容器流行的原因,还在于它提供了其它好处:
- Agile application creation and deployment: increased ease and efficiency of container image creation compared to VM image use.
- Continuous development, integration, and deployment: provides for reliable and frequent container image build and deployment with quick and easy rollbacks (due to image immutability).
- Dev and Ops separation of concerns: create application container images at build/release time rather than deployment time, thereby decoupling applications from infrastructure.
- Observability not only surfaces OS-level information and metrics, but also application health and other signals.
- Environmental consistency across development, testing, and production: Runs the same on a laptop as it does in the cloud.
- Cloud and OS distribution portability: Runs on Ubuntu, RHEL, CoreOS, on-prem, Google Kubernetes Engine, and anywhere else.
- Application-centric management: Raises the level of abstraction from running an OS on virtual hardware to running an application on an OS using logical resources.
- Loosely coupled, distributed, elastic, liberated micro-services: applications are broken into smaller, independent pieces and can be deployed and managed dynamically – not a monolithic stack running on one big single-purpose machine.
- Resource isolation: predictable application performance.
- Resource utilization: high efficiency and density.
Kubernetes 提供一个框架来弹性的运行分布式系统。它为你的应用关注 缩放 和 故障切换,
如果一个应用可以容器中运行,那么它应该可以在 Kubernetes 上运行很好。
Reference:https://kubernetes.io/docs/concepts/overview/what-is-kubernetes/
Link:https://www.cnblogs.com/farwish/p/11743036.html