3/21/2024 0 Comments Linux docker remove containerTo attach to currently running container use following command. To start container use following command. You can start, stop or attach to any containers with following commands. # docker ps -aĦb5b5a969241 centos "/bin/bash" 2 days ago Exited (0) 24 hours ago ubuntu-web To list all containers (including stopped container) use following command. # docker psĬONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMESį2582758af13 ubuntu "/bin/bash" 2 hours ago Up 2 hours first_ubuntuīy default Above command will list only running containers. List Docker ContainersĪfter existing from Docker container, execute below command to list all running containers. Click here to read for more options about docker run command. If you used exit command, it will stop the current container. This will leave container running in background an provide you host system console. To exit from docker container type CTRL + P + Q. To list all available images use docker images command. # docker run įor example below command will create new docker container using the image named “ubuntu”. This will start a new container and provide you access to that container with /bin/bash shell. To launch a new Docker container using below command. This tutorial will help you to create, list & delete docker containers on Linux machine. After that created containers with images. In our previous tutorials you have learned about installation of Docker engine on CentOS/RHEL and Ubuntu operating system and pulled images from Docker hub.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |