Docker for DevOps Engineers:

Docker for DevOps Engineers:

Docker plays a major role in building the application by improving its efficiency. It containerizes the application by creating an image which is portable i.e. can be run anywhere in any specification of the server.

Here comes the base of Docker which is called a Docker file. Let's learn what is it and how it sets a standard from application to apply through its configuration.

Installing Docker:

apt-get install docker.io -y

Check the version of Docker:

docker --version

Tasks:

Use the docker run command to start a new container and interact with it through the command line.

docker pull python

To check all images:

docker images

Create a container from the image:

docker run -it <image name> /bin/bash

To see all containers:

docker ps -a

Use the docker inspect command to view detailed information about a container or image.

docker inspect <container name>

Create and port a container:

sudo docker run -td --name <container name> -p 80:80 ubuntu

Use the docker port command to list the port mappings for a container.

docker port <container name >

Use the docker stats command to view resource usage statistics for one or more containers.

docker stats <docker name>

Use the docker top command to view the processes running inside a container

docker top <container name or id>

Use the docker save command to save an image to a tar archive.

docker save -o <image>.tar <image name>

********************************THANKYOU********************************