---
# System prepended metadata

title: Docker
tags: [2023 軟體培訓]

---

# Docker

## What is Container

![](https://boxboat.com/2018/12/11/what-is-a-container/container-vs-vm.png)

![](https://hackmd.io/_uploads/rJGmfLvMa.png)

為什麼我們要用 container:
- 輕量(相較於 VM)
- 統一開發環境
- 方便部屬

## Docker Architecture

![](https://docs.docker.com/get-started/images/docker-architecture.png)

```
docker run [OPTIONS] IMAGE [COMMAND] [ARG...]
```
```
docker build [OPTIONS] PATH | URL | -
```
```
docker pull [OPTIONS] NAME[:TAG|@DIGEST]
```

## References

- https://docs.docker.com/get-started/overview/
- https://philipzheng.gitbook.io/docker_practice/introduction/what