XK0-005 · Question #637
An administrator would like to list all current containers, regardless of their running state. Which of the following commands would allow the administrator to accomplish this task?
The correct answer is A. docker ps -a. The best command to use to list all current containers, regardless of their running state, is A) docker ps -a. This command will show all containers, both running and stopped, with details such as container ID, image name, status, and ports. The other commands are either…
Question
An administrator would like to list all current containers, regardless of their running state. Which of the following commands would allow the administrator to accomplish this task?
Options
- Adocker ps -a
- Bdocker list
- Cdocker image ls
- Ddocker inspect image
How the community answered
(23 responses)- A91% (21)
- B4% (1)
- C4% (1)
Explanation
The best command to use to list all current containers, regardless of their running state, is A) docker ps -a. This command will show all containers, both running and stopped, with details such as container ID, image name, status, and ports. The other commands are either invalid or not relevant for this task.
Topics
Community Discussion
No community discussion yet for this question.