gpt4 book ai didi

docker - 为什么几乎所有docker库镜像都是从源而不是从软件包系统构建的?

转载 作者:行者123 更新时间:2023-12-02 19:30:01 25 4
gpt4 key购买 nike

为什么几乎所有docker库(标准)镜像都是从源而不是从软件包系统构建的?

我调查了https://hub.docker.com/u/library/

  • https://hub.docker.com/_/nginx/
  • https://hub.docker.com/_/httpd/
  • https://hub.docker.com/_/php/
  • https://hub.docker.com/_/node/

  • 特别是对于 alpine linux,这是否具有逻辑解释?

    最佳答案

    官方答案:https://github.com/docker-library/official-images/issues/3517

    There's not any clear answer on which to prefer simply because we defer to upstream's official recommendations on a case-by-case basis. For example, in the postgres image's Debian variants, we consume the .deb packages built and published by the upstream project, but in the Alpine variants we have to build from source (since upstream does not publish Alpine packages and instead recommends building from source for platforms for which they do not publish their own packages).

    In httpd, Apache upstream does not publish any binary packages, and we thus build from source.

    In openjdk, we install packages built by Debian, Alpine, etc. simply because OpenJDK itself is very difficult and time-consuming to build from source, and because upstream officially recommends those packages as a suitable source of OpenJDK.

    关于docker - 为什么几乎所有docker库镜像都是从源而不是从软件包系统构建的?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52459196/

    25 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com