In this getting started tutorial we will learn about Docker.
Docker is an open source containerization software platform that enables us to build, deploy, run, update and manage our application.
Head over to https://www.docker.com/ and download the latest version of Docker as per the OS on your machine.
If you are on Windows, Mac or Linux then you can also check out Docker Desktop.
Dockerfile is a text based document that contains instruction like what base image to use for our application, environment variables to set, ports to expose, files to copy and many other things as per requirement to create a Docker Image.
A Docker Image is a file that acts as an immutable template to create Docker Container.
A Docker Container is the runtime instance of the Docker Image. A container is created when we run the docker run command and provide the Docker image name.
The following image explains how everything works.
We first create Dockerfile. Then we build the Docker Image by passing the Dockerfile to the docker build command. After that we create Docker Container by passing the docker image to the docker run command.
In the next tutorial we will look into some of the important Docker commands.
Have fun learning :-)
Copyright © 2014 - 2023 DYclassroom. All rights reserved.