Docker Learning – Sujit

Write a 1 post with following answers.
– What is Docker – in 2 lines

Docker is a tool which is used to create, deploy, and run applications by using containers.


– What is Container – in 3 lines

Container can be used to deploy a particular application or environment.

containers package all the code, libraries, and dependencies together and multiple containers can run in the same host, so that we can use that host’s resources more efficiently.
– Top 10 commands with 1 example of using docker container.

create

docker create –name=sujit httpd

start

docker start sujit

stop

docker stop sujit

restart

docker restart sujit

pause

docker pause sujit

unpause

docker unpause sujit

kill

docker kill sujit

remove

docker rm sujit

ls

list of containers

exec

docker exec container_ID ls


– 5 commands with 1 example of using docker image

Pull:

docker pull Imagename

docker images

docker image history -h sujit

docker image rm sujit

docker tag sujit sujit_hello

docker image push


– 5 commands with 1 example of using docker registry

login

docker login

logout

docker logout

images

docker images

tag

docker tag Imagename hubname

push

docker push hubname

Subscribe
Notify of
guest

This site uses Akismet to reduce spam. Learn how your comment data is processed.

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x