
何打
复制#Dockerfilewith cacheFROM fedora:28LABEL maintainer ChrisCollins<collins.christopher@gmail.com>RUN dnf install -y nginx-----#Dockerfilew/o cacheFROM fedora:28LABEL maintainer ChrisCollins<collins.christopher@gmail.com>RUN dnf install -y nginx \&& dnf clean all \&&rm-rf /var/cache/yum-----[chris@krang] $ docker build -t cache -f Dockerfile.[chris@krang] $ docker images --format "{{.Repository}}: {{.Size}}"|head-n 1cache:464 MB[chris@krang] $ docker build -t no-cache -f Dockerfile-wo-cache .[chris@krang] $ docker images --format "{{.Repository}}: {{.Size}}"|head-n 1no-cache:271 MB1.2.3.4.5.6.7.8.9.10.11.12.13.14.15.16.17.18.19.20.21.22.23.24.25.26.
(责任编辑:应用开发)