Docker — Part 1

Usha Devasi
3 min readMay 15, 2020

In today’s time, no conversation about containers or even microservices is complete without Docker.

Docker Background:

Docker is at the very least, two things. There’s the company, Docker Inc., and there’s the technology Docker.
Docker word is a British word and is a conjunction of doc and worker.
Originally, it was a company called dotCloud which later got named as Docker, it's quite interesting to know about how a company name got changed with there in-house built containerization tool. In this article, we gonna discuss Docker Technology.

What is DOCKER?

Docker is a platform for developers and system admins to build, run, and share applications with containers. The use of containers to deploy applications is called containerization. Containers are not new, but their use for easily deploying applications is.

Containerization is increasingly getting popular because :

  • Lightweight: Containers leverage and share the host kernel, making them much more efficient in terms of system resources than virtual machines.
  • Flexible: Even the most complex applications can be containerized.
  • Loosely coupled: Containers are highly self-sufficient and encapsulated, allowing you to replace or upgrade one without disrupting others.
  • Portable: Can be built locally, deploy to the cloud, and run anywhere. So, it erases the problem of the code where it is working on some environment but not on others.
  • Scalable: Container replicas across a data centre can be increased and automatically distributed
  • Secure: Containers apply aggressive constraints and isolations to processes without any configuration required on the part of the user.

Containers 🏺? 🤔

Logically its a jar, yes. But in the technical term, we can say a container is nothing but a running process, with some added encapsulation features applied to it in order to keep it isolated from the host and from other containers.
One of the most important aspects of container isolation is that each container interacts with its own private filesystem; this filesystem is provided by a Docker image.

What is Docker Image?
An image includes everything needed to run an application — the code or binary, runtimes, dependencies, and any other filesystem objects required.

I gonna explain the docker image in part2 but let me tell you how the container is different from VM’s and how container more efficient 😊 for our pockets.

VM’s and Containerization:
Virtual machine manager or a hypervisor, it grabs physical resources like CPU, RAM, storage, networks. Then, it slices them into virtual versions, so virtual CPU, virtual RAM, virtual NICs, all that goodness, and then it builds virtual machines out of them, virtual machines that look, smell, and feel like normal physical servers.

image source

Well, not the same with containers.
Instead of slicing and dicing physical server resources, Docker and other container engines slice and dice operating system resources. So they slice up the process namespace, the network stack, the storage stack, or the filesystem hierarchy actually.
In effect, every container gets its own PID1, process ID 1. Every container gets its own root filesystem. That’s obviously slashed on Linux and C on Windows. So hypervisor virtualization virtualizes physical server resources and builds virtual machines. Container engines like Docker, they’re more like operating system virtualization. They create virtual operating systems, assign one to each container, inside of which we run applications.

Let’s cover Docker in detail in Docker-Part 2.
Now, hope you got a clear idea about Docker, to have a basic understanding before driving deep into the topic.

For more study, refer Docker official site.
Stay Safe.

--

--

Usha Devasi

Tech Lead/ Engineering Manager, Mentor, Coach, Certified Professional Scrum Master and SomeOne who is Passionate about Learning and exploring.