Author : HASSAN MD TAREQ | Updated : 2021/05/24
- A container is an atomic unit of software that packages up code, dependencies, and configuration for a specific application
- A lightweight and portable executable image that contains software and all of its dependencies
- Container is an abstraction on application layer (they package all the code, libraries, and dependencies together)
- Packaging an app with its dependences and some necessary services
- Small and lightweight execution environments that make shared use of the operating system kernel but otherwise run in isolation from one another
- Containers are isolated from one another and bundle their own software, libraries and configuration files
- Containers can communicate with each other through well-defined channels
A container is a loosely isolated environment that allows us to build and run software packages. These software packages include the code and all dependencies to run applications quickly and reliably on any computing environment.
Containerized applications deployment necessitates three categories of software:
- Builder: technologies used to build container (docker)
- Engine: technologies used to run container i.e. containered (docker container)
- Orchestration: technologies used to manage many containers (i.e. Kubernetes)
Containers are isolated from one another but run on a shared OS kernel, making them far more lightweight than virtual machines. This allows more containers to be run on the same physical hardware giving containers an advantage over traditional virtual machines.
- Containerizing: the code, its dependencies, and runtime are packaged into a binary called a container image
- A container image is a portable package that contains software. It’s this image that, when run, becomes our container
- The container is the in-memory instance of an image
- A container image is a ready-to-run software package, containing everything needed to run an application
- Container image contains the code and any runtime it requires, application and system libraries, and default values for any essential settings
- By design, a container is immutable: you cannot change the code of a container that is already running. If you have a containerized application and want to make changes, you need to build a new image that includes the change, then recreate the container to start from the updated image
- A container is an instance of an image
How Does Docker Work?
Docker packages an application and it’s dependencies in a virtual container that can run on any Linux server. Since they have all the necessary dependencies contained in a single piece of software, this is why the are called containers.
Docker is composed of the following elements:
- A Daemon: used to build, run, and manage the containers
- A high-level API: allows the user to communicate with the Daemon
- A CLI: the interface we use to make this all available
Public repository for docker container.