Docker and its Uses

Himavarsha Madala
6 min readOct 5, 2021

Docker is an open source platform for building, deploying, and managing containerized applications. Learn about containers, how they compare to VMs, and why Docker is so widely adopted and used.

What is Docker?

Docker is an open source containerization platform. It enables developers to package applications into containers — standardized executable components combining application source code with the operating system (OS) libraries and dependencies required to run that code in any environment. Containers simplify delivery of distributed applications, and have become increasingly popular as organizations shift to cloud-native development and hybrid multicloud environments. Developers can create containers without Docker, but the platform makes it easier, simpler, and safer to build, deploy and manage containers. Docker is essentially a toolkit that enables developers to build, deploy, run, update, and stop containers using simple commands and work-saving automation through a single API.

Solomon Hykes built a wonky open-source project a decade ago that later took on the name Docker and attained a private market valuation of over $1 billion. A developer community in the millions, under the leadership of our CEO, the legendary Steve Singh,” Hykes wrote. “To take advantage of this opportunity, we need a CTO by Steve’s side with decades of experience shipping and supporting software for the largest corporations in the world.”

Know about your software:

Docker is a set of platform as a service (PaaS) products that use OS-level virtualization to deliver software in packages called containers.[6] Containers are isolated from one another and bundle their own software, libraries and configuration files; they can communicate with each other through well-defined channels. Because all of the containers share the services of a single operating system kernel, they use fewer resources than virtual machines.

components: software, objects, registries

How do container work?

Containers are made possible by process isolation and virtualization capabilities built into the Linux kernel. These capabilities — such as control groups (Cgroups) for allocating resources among processes, and namespaces for restricting a processes access or visibility into other resources or areas of the system — enable multiple application components to share the resources of a single instance of the host operating system in much the same way that a hypervisor enables multiple virtual machines (VMs) to share the CPU, memory and other resources of a single hardware server.

Use of containers:

Many containers can be bundled in a single server as there is no operating system duplication for individual applications. One of the main advantages of Docker is portability across different environments. Containers of Docker can either run on simple metal server or above virtual machines. They can either run on cloud or on-premises. These features have led to its influence on software developments and the familiar use cases for containers are software application development and deployment. The programmers can compile applications and keep them inside the Docker container after which the application gets moved over different environments. These applications resemble capsules placed inside containers. Unlike the VMs, Docker never creates a tank of applications. Docker is light-weighted and thus offers higher flexibility reducing bulk resources. The same Docker container is capable of running on both AWS and the cloud, which is not possible by virtual machines. Docker creates a neat configuration and deployment environment for its users.

Data center with VM’s and Containers

Containerization

Containerization is OS-based virtualization which creates multiple virtual units in the userspace, known as Containers. Containers share the same host kernel but are isolated from each other through private namespaces and resource control mechanisms at the OS level. Container-based Virtualization provides a different level of abstraction in terms of virtualization and isolation when compared with hypervisors.

Hypervisors use a lot of hardware which results in overhead in terms of virtualizing hardware and virtual device drivers. A full operating-system (e.g -Linux, Windows) run on top of this virtualized hardware in each virtual machine instance. But in contrast, containers implement isolation of processes at the operating system level, thus avoiding such overhead. These containers run on top of the same shared operating system kernel of the underlying host machine and one or more processes can be run within each container. In containers you don’t have to pre-allocate any RAM, it is allocated dynamically during the creation of containers while in VM’s you need to first pre-allocate the memory and then create the virtual machine.

Containerization has better resource utilization compared to VMs and a short boot-up process. It is the next evolution in virtualization. Containers are able to run virtually anywhere, greatly easy development and deployment: on Linux, Windows, and Mac operating systems; on virtual machines or bare metal, on a developer’s machine or in data centers on-premises; and of course, in the public cloud. Containers virtualize CPU, memory, storage, and network resources at the OS-level, providing developers with a sandboxed view of the OS logically isolated from other applications. Docker is the most popular open-source container format available and is supported on Google Cloud Platform and by Google Kubernetes Engine.

Docker Architecture

Docker architecture consists of Docker client, Docker Daemon running on Docker Host, and Docker Hub repository. Docker has client-server architecture in which the client communicates with the Docker Daemon running on the Docker Host using a combination of REST APIs, Socket IO, and TCP. If we have to build the Docker image, then we use the client to execute the build command to Docker Daemon then Docker Daemon builds an image based on given inputs and saves it into the Docker registry. If you don’t want to create an image then just execute the pull command from the client and then Docker Daemon will pull the image from the Docker Hub and finally if we want to run the image then execute the run command from the client which will create the container.

To Run docker in your linux system

To run docker in your windows as selenium grid

Uses of Docker:

The Docker technology is being rapidly adopted by major leading companies of the world due to its optimistic developer experiences, image portability and convenient and easy deployment. The containers in Docker is simple to build and easy for local deployment on both conventional systems as well as Cloud services. Dockers are easy to move locally.
Majority of companies look at Docker as the best solution for developing cloud based services or micro-applications. Cloud Provider needs faster environment for iterating their applications. In cases where Docker represents micro-services or a broad deployment application, Docker must be tied along with workflow managers. This is mainly true for conditions where some components get developed on Cloud and then undergo on-premise deployment and even vice versa.

In Industry like:

1.eBay

2.spotify

3.ING

4.IBM

5.GILT

6.Google

7.YELP

Conclusion:

Docker, an open-source container technology has taken over server virtualization field, providing what is seen as quicker alternative for running complete VM (Virtual Machines) over the hypervisors. With recent Docker release, the building team behind Docker is focusing on creating Docker capable for enterprise usage. The result is that container technology could be faster, utilizing less system resources than that of virtual machines, if the developer is willing on sticking to a single environment that that provide shared operating system.

The creation of a complete virtual machine or VM may consume several minutes for creating and launching but Docker’s container technology can be started in just few seconds. Docker also offers high performance rates for contained applications. This is pretty much faster while comparing to applications that run on a virtual machine which faces operation overhead of using hypervisors. The application that runs on Docker is two times faster than the applications that are running inside a VM or virtual machine.

--

--