Skip to content

Commit

Permalink
修改github md 在shell中#生效的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
whyfate committed Nov 26, 2023
1 parent 79f019a commit 38390f9
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions blogs/docker/2017-10-13-docker一些命令记录.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,16 +29,21 @@ docker [info|version]

* 常用命令整理
```shell
# docker 与 服务器 相互拷贝
sudo docker cp $hostPath <containerId>:/
sudo docker cp <containerId>:/ $hostPath
// 列出所有容器
sudo docker ps

# 进入容器
// 进入容器
sudo docker exec -it <containerId> /bin/bash

# 删除 tag 或者 image 为 none 的镜像
// 列出容器信息
sudo docker inspect <containerId>

// 列出所有带dotnet关键字的镜像
sudo docker images | grep dotnet

// 删除 tag 或者 image 为 none 的镜像
sudo docker rmi -f $(sudo docker images | awk '/<none>/ { print $3 }')

# 查看容器运行状态,CPU、Memory消耗情况
// 查看容器运行状态,CPU、Memory消耗情况
docker stats
```

0 comments on commit 38390f9

Please sign in to comment.