What is Docker and Docker Image
In this blog we will try to understand one of most popular tools used to containerize and deploy applications over the internet i.e. Docker. It make deploying applications extremely simple.
We will try to look at the things that make it so special and learn how to create, deploy, run applications by using containerization technology.
So, here we go
Have you ever think how Operating System work if no so let se,
When you install OS step we follow:
DVD --> Program --> Process --> OS install --> Boot --> = provisioning
You know normally one OS need 6-7 GB of storage and take 30-40 min in booting and installing but docker technology can launch OS in 1 sec.
For Installing any OS we require Image/DVD for launching Container we need docker image. Docker Community has its own internal URL at Redhat/Centos they put in one public repository known as docker hub.public.com you can create your own private registry that we will discuss later.
Docker pull centos:07
with above command docker will download image from public repository
docker run -i -t --name myos1 centos:07
This will launch new container in just sec.
Docker will launch new container in just 15-20 mb
Now let's move ahead till here we got to know what is docker how it work,
Let's suppose we are working in Docker Container in this we download some software from internet or you create some pages at the same time your friend also want to work on that page so what you will do?? Docker has an amazing facility to create image of current OS
Recommended by LinkedIn
docker commit myos1 myimage:v1
This will create a new image with additional software and your pages now you also can upload this in docker hub.public.com and copy as many OS as you want this process is known as cloning. You can launch container with this image:
docker run --it --name myOS2 myimage:v1
Docker Engine
It consists of 3 main components :
Push an Image to Docker Hub
docker tag <image-id> <your dockerhub username>/myimage:v1
docker push <user name>/myimage
Great one