Mobile wallpaper 1Mobile wallpaper 2Mobile wallpaper 3Mobile wallpaper 4Mobile wallpaper 5Mobile wallpaper 6
179 字
1 分钟
Docker

Docker#

一、部署#

1. 打开适用于#
2. 安装 wsl#
wsl --install
wsl --update
// 安装ubuntu
wsl -l -o
wsl --install -d Ubuntu

二、常用命令#

// 拉取镜像
docker pull 镜像名
// 删除镜像
docker rmi
// 查看已拉取镜像
docker images
// 创建并运行容器
docker run [-d] [-p 宿主端口:容器端口] [-v 文件目录路径] [-e xxx=xxx] \ ... 镜像名
// 创建容器
docker create [-d] [-p 宿主端口:容器端口] [-v 文件目录路径] [-e xxx=xxx] \ ... 镜像名
// 删除容器
docker rm -f 容器ID
// 运行容器
docker start 容器ID
// 停止容器
docker stop 容器ID
// 查看所有运行中容器
docker ps [-a]
docker exec 容器ID [linux命令]
docker exec -it 容器ID
Docker
https://www.zangmiyu.com/posts/dockers/
作者
zangmiyue
发布于
2026-01-10
许可协议
CC 脏谜语

部分信息可能已经过时