> For the complete documentation index, see [llms.txt](https://moekiwisama-1.gitbook.io/minecraft-docker/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://moekiwisama-1.gitbook.io/minecraft-docker/nginx/docker-ps.md).

# docker ps

我们通过 docker ps 来查看当前正在运行的容器，其中的 container id 就是上文运行 nginx 服务时，回显字符串的前 12 个字符

```bash
docker ps
```

![](https://4102141993-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-McxO38P3xiLG7yDv_Y1%2F-McxqFZbViWutVZ6JhYS%2F-McxsYXsUGHZ_SOlO-Dt%2Fimage.png?alt=media\&token=c6b58b0a-6bfa-4a4b-8470-6e5fffa0737d)

图中展示了上一篇文章正在运行的两个 docker image，他们正在后台跑着

我们也可以通过 docker ps -a 查看所有的，包括已经关闭的 docker 实例

![](https://4102141993-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-McxO38P3xiLG7yDv_Y1%2F-McxqFZbViWutVZ6JhYS%2F-McxspnEG5Mx-0YNDynB%2Fimage.png?alt=media\&token=f1c41e98-bad1-4271-abca-e6ed2fe75cec)

例如图中展示了之前关闭的 nginx 实例和一开始自己退出的 hello-world 实例
