Container Fundamentals — Part I

Nived Velayudhan
techbeatly
Published in
3 min readMay 31, 2020

A container is a unit of software that wraps an application code, runtime, system tools, system libraries, and dependencies, etc. Containers are built off Container images.

Containers are just processes running in your system. Unlike a VM which provides hardware virtualization, a container provides operating-system-level virtualization by abstracting the “user space”.

Virtualization vs Containerization:

VMs run on top of a host machine using a hypervisor. The host machine provides the VMs with resources, including RAM and CPU.

The VM that is running on the host machine is also often called a “guest machine.” This guest machine contains an entire OS that has both the application and the system binaries/libraries it needs to run that application. It also has its own virtualized network adapters, storage, and CPU, RAM, etc.

Containers may look like a VM. For example, containers can execute commands as root, have a private network interface and an IP Address, allow custom firewall rules, can mount file systems, etc.

In the case of Containers, each container gets its own isolated userspace to allow multiple containers to run on a single host machine. Containers share the host system’s kernel with other containers. We can see that all the operating system level architecture is being shared across containers. The only parts that are created from scratch are the bins and libs. This is what makes containers so lightweight.

Benefits of Containers

  • Containers are lightweight: Containers require fewer system resources than traditional or hardware virtual machine environments because they don’t include operating system images.
  • Containers are portable: A container wraps up an application with everything it needs to run, like configuration files and dependencies. This enables you to easily and reliably run applications on different environments such as your local desktop, physical servers, virtual servers, and public or private clouds
  • Better resource utilization: Since containers do not require a separate operating system, they use up fewer resources.
  • Faster Application Development: Containers allow applications to be more rapidly deployed, patched, or scaled.
  • Faster Deployment: Since containers wrap up an entire application and its dependencies, it is not dependant on the environment in which it was created thus making testing and debugging less complicated and less time-consuming
  • Supports modern development and architecture: Due to its low size, consistency, and portability, it is an ideal fit for a modern development framework — DevOps, Serverless & Microservices.

Container Use Cases

  • IoT devices: Since container images are small portable packages and are very easy to install, update, and require minimal processing power, they are ideal for IoT devices.
  • Containers as a Service ( CaaS ): Container engines, orchestration, and underlying computer resources delivered as a service through cloud vendors.
  • Microservices: Containers are used to decouple monolithic applications into reusable components by building container images.
  • DevOps support: Container technology supports streamlined build, test, and deployment from the same container images.

--

--

Nived Velayudhan
techbeatly

I help businesses solve their IT challenges such as automation and containerization on hybrid cloud environments by using customized open source solutions.