[root@localhost downloads]# docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
docker.io/hello-world latest e38bc07ac18e 2 months ago 1.85 kB
[root@localhost downloads]# docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
3fa4f2de1c01 hello-world "/hello" 4 minutes ago Exited (0) 4 minutes ago elastic_lumiere
docker ps也是最常用的命令,-a :显示所有的容器,包括未运行的。
2.3使用docker logs查看容器控制台输出获取容器的日志
docker logs [container]
Linux公社的RSS地址:https://www.linuxidc.com/rssFeed.aspx