Containers
-> a standard unit of software that packages up code and all its dependencies so the application runs quickly and reliably from one computing environment to another.
-> Containers are a lightweight alternative to full machine virtualization
-> A Docker container image is a lightweight, standalone, executable package of software that includes everything needed to run an application: code, runtime, system tools, system libraries and settings.
-> docker hub - Public repository for container
Docker image -> is just a template of the environment you want (with the OS/App/App dependencies etc) - read-only filesystem
Docker (Containers, isolated env for application)
-> Docker is a containerization platform (configuring, building and distributing) that packages your application and all its dependencies together in the form of a docker container to ensure that your application works seamlessly in any environment.
-> Automated Building and deploying application - CICD - continuous integration and continuous deployment.
-> single instance of application -> docker run my-web-server
-> Download & Install docker -> docker run postgress
-> Running container -> docker ps
Disadvantages:
-> Containers don't run at bare-metal speeds
-> some container products don't work with other ones
-> Persistent data storage is complicated.(There are ways to save data persistently in Docker, such as Docker Data Volumes)
-> Graphical applications don't work well
kubernatives - K8S - (open-source container-orchestration system)
-> High availability, scalability, DR
-> Infra for managing multile containers
-> Automated scheduling and management of application containers
-> Ecosystem to manage a cluster of docker containers
Master node -> Manage cluster - API server(UI/API/CLI - YAML,JSON),Control manager, scheduler, etcd
Worker nodes -> run application - > POD (container - inside pod), POD per application
die/Recreate POD -> new POD -> new IP -> Not good -> Service (Permanent IP & Load balance)
-> kubectl run --replicas=1000 my-web-server
-> kubectl scale --replicas=2000 my-web-server
-> kubectl rolling-update .....