filmov
tv
Most asked docker commands to Java Developer | Interview Questions | Experienced | Code Decode
Показать описание
In this video of code decode we have explained most asked docker commands Interview questions for freshers and freshers
Udemy Course of Code Decode on Microservice k8s AWS CICD link:
Course Description Video :
Docker Commands Cheatsheet for Java Developer
How to check for Docker Client and Docker Server version
docker version
How do you get the number of containers running, paused and stopped?
docker info
You can get the number of containers running, paused, stopped, the number of images and a lot more.
How to build a Dockerfile?
docker build path to docker file
Once you’ve worked with an image, how do you push it to docker hub?
docker push username/image name
How to pull an image from docker hub onto your local system
docker pull image_name
How do you create a docker container from an image?
docker run -it -d image_name
-d means the container needs to start in the detached mode. Logs will not be seen in command prompt rather it will run in background like daemon thread
The -it (--interactive + --tty ) options tells Docker to keep the standard input attached to the terminal and starts the container in the interactive mode.
How do you list all the running containers
docker ps
docker ps -a - show all the running and exited containers
Suppose you have 3 containers running and out of these, you wish to access one of them. How do you access a running container?
docker exec -it container id bash
The following command lets us access a running container
How to debug / see logs of our Docker containers.
docker logs container_id
How to start, stop and kill a container?
docker start container_id
docker stop container_id
docker kill container_id
docker rm container id - delete a stopped container:
How to delete an image from the local storage system?
docker rmi image-id
lists all the locally stored docker images
docker images
How to know the details of the list of networks in the cluster
docker network ls
Hibernate Interview Questions and Answers:
Spring Boot Interview Questions and Answers:
Subscriber and Follow Code Decode
#docker #dockerinterviewquestions #codedecode
Udemy Course of Code Decode on Microservice k8s AWS CICD link:
Course Description Video :
Docker Commands Cheatsheet for Java Developer
How to check for Docker Client and Docker Server version
docker version
How do you get the number of containers running, paused and stopped?
docker info
You can get the number of containers running, paused, stopped, the number of images and a lot more.
How to build a Dockerfile?
docker build path to docker file
Once you’ve worked with an image, how do you push it to docker hub?
docker push username/image name
How to pull an image from docker hub onto your local system
docker pull image_name
How do you create a docker container from an image?
docker run -it -d image_name
-d means the container needs to start in the detached mode. Logs will not be seen in command prompt rather it will run in background like daemon thread
The -it (--interactive + --tty ) options tells Docker to keep the standard input attached to the terminal and starts the container in the interactive mode.
How do you list all the running containers
docker ps
docker ps -a - show all the running and exited containers
Suppose you have 3 containers running and out of these, you wish to access one of them. How do you access a running container?
docker exec -it container id bash
The following command lets us access a running container
How to debug / see logs of our Docker containers.
docker logs container_id
How to start, stop and kill a container?
docker start container_id
docker stop container_id
docker kill container_id
docker rm container id - delete a stopped container:
How to delete an image from the local storage system?
docker rmi image-id
lists all the locally stored docker images
docker images
How to know the details of the list of networks in the cluster
docker network ls
Hibernate Interview Questions and Answers:
Spring Boot Interview Questions and Answers:
Subscriber and Follow Code Decode
#docker #dockerinterviewquestions #codedecode
Комментарии