Docker Overview

Docker Overview

Why do you need docker?

  • Docker is an open source platform that enables developers to build, deploy, run, update and manage containers.

  • Docker provides the ability to package and run an application in a loosely isolated environment called a container.

  • To Resolve Dependency and Compatibility Issues, Setup time reduction, Unlike different Dev/Staging/Prod Environments.

What can it do?

  • Docker can quickly deploy and scale applications into any environment and know your code will run.

  • Docker run each service with its own dependencies in separate containers.

  • Docker run in isolated packages of code called containers and the applications known Containerized applications

What are Containers?

  • Containers are packages of software that contain all of the necessary elements to run in any environment.

  • In this way, containers virtualize the operating system and run anywhere, from a private data center to the public cloud or even on a developer’s personal laptop

  • Containers are executable units of software in which application code is packaged along with its libraries and dependencies, in common ways so that the code can be run anywhere whether it be on desktop, traditional IT or the cloud.

  • Containers are completely isolated environments. as they can have there own Process Own Network Own Mounts For ex containers are LXC, LXD, LXCFS etc.

  • Docker utilizes LXC Container.

Containers vs Virtual Machines

  • Virtual machines are heavy software packages that provide complete emulation of low level hardware devices like CPU, Disk and Networking devices.

  • Containers are lightweight software packages that contain all the dependencies required to execute the contained software application. These dependencies include things like system libraries, external third-party code packages, and other operating system level applications.

  • Container Hardware--> Infrastructure-->OS-->Docker-->Application(Libs, Deps)-->Container(Utilization is less, Size is in MB, Boot up is faster than VM)

  • Virtual Machines--> Hardware Infrastructure-->Hypervisor-->Application(Libs, Deps)-->Virtual Machine(Utilization is less, Size is in MB, Boot up is faster than VM)

How is it done?

  • Docker uses a client-server architecture.

  • The Docker client talks to the Docker daemon, which does the heavy lifting of building, running, and distributing your Docker containers

  • It have Public Docker registry - docker hub

  • docker run ansible, docker run mongodb, docker run redis, docker run nodejs

Container vs Image

  • A Docker container is a self-contained, runnable software application or service.

  • Docker image is the template loaded onto the container to run it, like a set of instructions.

  • Image is a package or template VM template

  • Container are running instances of images that are isolated and have their own environments and set of process.

Docker in DevOps

  • Docker is an open platform for developing, shipping and running applications

  • Developer-->Operation Team-->(App.war, Docker file)-->Docker Image

If you liked what you read, do follow and Any feedback for further improvement will be highly appreciated!

Thank you and Happy Learning!👏