【发布时间】:2021-02-28 14:28:06
【问题描述】:
我遇到了以下 Dockerfile。
FROM registry
# I am not clear what this is.
# I do not understand the following comment either.
# tree is helpful to peruse filesystem storage of images
RUN apk add --no-cache tree
对于apk add,我得到了以下三个so链接。
- How can I install Docker inside an alpine container?
- Running "apk add" command in a docker container with arguments [closed]
- rhat8 equivalent of "apk add --no-cache gcc musl-dev linux-headers"
第一个链接中的This answer 说“在 alpine 中运行 docker”
有人可以请教我。为什么要在 docker 容器中运行 docker?
这是什么apk add?
【问题讨论】:
-
有效问题。我不明白反对票。这个问答帮助我意识到 apk 是 alpine linux 的默认包管理器,它在 docker 基础层中大量使用。
标签: docker