首页>>技术分享>>Linux>Docker傻瓜使用速成

Docker傻瓜使用速成

大路 Linux 2023-10-13 151
Docker 一键安装命令

curl -fsSLo- get.docker.com | /bin/sh





# 运行 hello-world 检查Docker引擎是否安装

docker run hello-world



# 运行一个 Ubuntu 容器

docker run -it ubuntu bash



# 显示所有的容器

docker ps -a



# 显示本机镜像

docker images



# 查看Ubuntu镜像的历史

docker history hello-world



# 查看镜像的历史

docker history ubuntu



#  删除所有容器

docker rm  -f  $(docker ps -qa)



#  删除所有镜像

docker rmi -f  $(docker images -qa)


标签: