erdc / conda_base

Dockerfile for conda-based installation of dependencies
0 stars 1 forks source link

Large image size with proteus-dev environment #1

Open zhang-alvin opened 4 years ago

zhang-alvin commented 4 years ago

The following is the output of docker history IMAGEID, which shows that the proteus-dev environment takes up 2GB of space leading to a total image size that's 3.3GB large. For comparison, the hashstack-based image is only 2GB large.

727ddbcd1ef6        2 hours ago         bash -lc #(nop)  ENV CONDA_DEFAULT_ENV=prote…   0B                  
<missing>           2 hours ago         bash -lc #(nop)  ENV PATH=/envs/proteus-dev/…   0B                  
<missing>           2 hours ago         |1 conda_env=proteus-dev bash -lc echo "sour…   28B                 
<missing>           2 hours ago         bash -lc #(nop)  ARG conda_env=proteus-dev      0B                  
<missing>           2 hours ago         bash -lc git clone https://github.com/erdc/p…   2.16GB              
<missing>           3 hours ago         bash -lc #(nop)  SHELL [bash -lc]               0B                  
<missing>           3 hours ago         /bin/sh -c #(nop) WORKDIR /home/jovyan          0B                  
<missing>           3 hours ago         /bin/sh -c #(nop)  USER jovyan                  0B                  
<missing>           3 hours ago         /bin/sh -c #(nop) WORKDIR /home/jovyan          0B                  
<missing>           3 hours ago         /bin/sh -c #(nop)  EXPOSE 8888                  0B                  
<missing>           3 hours ago         /bin/sh -c chown -R $NB_USER:users /opt/cond…   2.59kB              
<missing>           3 hours ago         /bin/sh -c chown -R $NB_USER:users /home/$NB…   4.8kB               
<missing>           3 hours ago         /bin/sh -c useradd -m -s /bin/bash -N -u $NB…   397kB               
<missing>           3 hours ago         /bin/sh -c #(nop)  ENV PATH=/opt/conda/bin:/…   0B                  
<missing>           3 hours ago         /bin/sh -c #(nop)  ENV LANGUAGE=en_US.UTF-8     0B                  
<missing>           3 hours ago         /bin/sh -c #(nop)  ENV LANG=en_US.UTF-8         0B                  
<missing>           3 hours ago         /bin/sh -c #(nop)  ENV LC_ALL=en_US.UTF-8       0B                  
<missing>           3 hours ago         /bin/sh -c #(nop)  ENV NB_UID=1000              0B                  
<missing>           3 hours ago         /bin/sh -c #(nop)  ENV NB_USER=jovyan           0B                  
<missing>           3 hours ago         /bin/sh -c #(nop)  ENV SHELL=/bin/bash          0B                  
<missing>           3 hours ago         /bin/sh -c wget --quiet https://repo.anacond…   213MB               
<missing>           3 hours ago         /bin/sh -c #(nop)  USER root                    0B                  
<missing>           3 hours ago         /bin/sh -c #(nop)  MAINTAINER Proteus Projec…   0B                  
<missing>           31 hours ago        /bin/sh -c echo "en_US.UTF-8 UTF-8" > /etc/l…   1.68MB              
<missing>           31 hours ago        /bin/sh -c apt-get update && apt-get -yq dis…   854MB               
<missing>           31 hours ago        /bin/sh -c apt-get update && apt-get -yq dis…   9.43MB              
<missing>           31 hours ago        /bin/sh -c #(nop)  ENV DEBIAN_FRONTEND=nonin…   0B                  
<missing>           31 hours ago        /bin/sh -c #(nop)  USER root                    0B                  
<missing>           31 hours ago        /bin/sh -c #(nop)  MAINTAINER Proteus Projec…   0B                  
<missing>           2 weeks ago         /bin/sh -c #(nop)  CMD ["/bin/bash"]            0B                  
<missing>           2 weeks ago         /bin/sh -c mkdir -p /run/systemd && echo 'do…   7B                  
<missing>           2 weeks ago         /bin/sh -c set -xe   && echo '#!/bin/sh' > /…   745B                
<missing>           2 weeks ago         /bin/sh -c [ -z "$(apt-get indextargets)" ]     987kB               
<missing>           2 weeks ago         /bin/sh -c #(nop) ADD file:594fa35cf803361e6…   63.2MB 

Within the ~/./conda/envs/proteus-dev environment, the following is the distribution of directory sizes:

8.0K    ./compiler_compat
8.0K    ./condabin
12K ./var
24K ./shell
56K ./man
68K ./qsci
164K    ./etc
320K    ./phrasebooks
336K    ./ssl
572K    ./doc
744K    ./lib64
3.5M    ./mkspecs
16M ./qml
19M ./plugins
21M ./conda-meta
21M ./resources
26M ./translations
114M    ./share
126M    ./x86_64-conda_cos6-linux-gnu
133M    ./bin
150M    ./libexec
158M    ./include
1.4G    ./lib
2.2G    .
zhang-alvin commented 4 years ago

List of libraries and sizes in conda env.

1.1M    libcholmod.so.3.0.13
1.1M    libGLU.a
1.1M    libgomp.so.1.0.0
1.1M    libiconv.a
1.1M    libomptarget.so
1.1M    libptscotch-6.so
1.1M    libptscotch.so
1.1M    libQt5UiTools.a
1.1M    libsuperlu.a
1.1M    libtbbmalloc.so.2
1.1M    libTKFeat.so.7.4.0
1.1M    libTKSTEPAttr.so.7.4.0
1.1M    libwebp.a
1.1M    python3.7/pydoc_data
1.2M    libapf_zoltan.so
1.2M    libfreetype.a
1.2M    libomp.so
1.2M    libQt5DataVisualization.so.5.12.5
1.2M    libQt5Network.so.5.12.5
1.2M    libQt5QuickTemplates2.so.5.12.5
1.2M    libQt5XcbQpa.so.5.12.5
1.3M    libglib-2.0.so.0.5800.3
1.3M    libsqlite3.so.0.8.6
1.3M    libTKG3d.so.7.4.0
1.3M    libTKHLR.so.7.4.0
1.3M    libTKOpenGl.so.7.4.0
1.3M    sqlite3.30.1.2
1.4M    libblosc.a
1.4M    libnspr4.so
1.4M    libnss3.so
1.4M    libTKOffset.so.7.4.0
1.4M    libX11.so.6.3.0
1.5M    ldscripts
1.5M    libQt5Script.so.5.12.5
1.6M    libcholmod.a
1.6M    libiberty.a
1.6M    libmds.so
1.6M    libQt5Charts.so.5.12.5
1.6M    libQt5Location.so.5.12.5
1.6M    libsuperlu_dist.a
1.6M    libtk8.6.so
1.6M    libumfpack.a
1.6M    tcl8.6/encoding
1.7M    libarchive.a
1.7M    libgmp.a
1.7M    libxml2.so.2.9.10
1.8M    libgettextlib-0.19.8.1.so
1.8M    libgstgl-1.0.so.0.1405.0
1.8M    libTKernel.so.7.4.0
1.8M    python3.7/lib2to3
1.9M    libgstbase-1.0.so.0.1405.0
1.9M    libpumi.so
1.9M    libQt5QmlDevTools.a
1.9M    libtcl8.6.so
1.9M    libzoltan.a
1.9M    tk8.6
2.0M    libgstaudio-1.0.so.0.1405.0
2.0M    python3.7/distutils
2.0M    python3.7/ensurepip
2.1M    libgio-2.0.so.0.5800.3
2.1M    libQt5DesignerComponents.so.5.12.5
2.1M    libsqlite3.a
2.2M    libicuuc.so.64.2
2.3M    cmake
2.3M    libzmq.a
2.3M    python3.7/encodings
2.4M    libcmumps-5.2.1.so
2.4M    libcrv.so
2.4M    libdmumps-5.2.1.so
2.4M    libQt53DRender.so.5.12.5
2.4M    libsmumps-5.2.1.so
2.4M    libTKBO.so.7.4.0
2.4M    libubsan.so.1.0.0
2.4M    libzmumps-5.2.1.so
2.4M    petsc/conf
2.4M    tcl8.6
2.5M    libChronoModels_vehicle.so
2.5M    libgstvideo-1.0.so.0.1405.0
2.5M    libTKXSBase.so.7.4.0
2.6M    liblsan.so.0.0.0
2.6M    libTKShHealing.so.7.4.0
2.6M    libTKSTEPBase.so.7.4.0
2.7M    libnspr4.a
2.7M    libtbb.so.2
2.7M    libTKMath.so.7.4.0
2.7M    petsc
2.8M    libTKFillet.so.7.4.0
2.9M    libQt5XmlPatterns.so.5.12.5
3.0M    libTKTopAlgo.so.7.4.0
3.0M    python3.7/idlelib
3.1M    libTKSTEP.so.7.4.0
3.2M    libcrypto.so.1.1
3.3M    libmpi.so.12.1.8
3.5M    libQt5Qml.so.5.12.5
3.7M    libicui18n.so.64.2
3.7M    libpython3.7m.so.1.0
3.7M    python3.7/__pycache__
3.8M    libQt5Quick.so.5.12.5
3.8M    libTKV3d.so.7.4.0
4.0M    libQt5Bootstrap.a
4.1M    libHYPRE.so
4.1M    libph.so
4.1M    libQt5Gui.so.5.12.5
4.1M    libTKBool.so.7.4.0
4.1M    libTKIGES.so.7.4.0
4.2M    libhdf5.so.103.1.0
4.3M    libma.so
4.3M    libQt5Designer.so.5.12.5
4.4M    libQt5Core.so.5.12.5
4.5M    libChronoEngine_vehicle.so
5.3M    libLIEF.so
5.3M    libparma.so
5.3M    libQt5Widgets.so.5.12.5
5.4M    libgstreamer-1.0.so.0.1405.0
5.4M    libTKGeomBase.so.7.4.0
5.7M    libapf.so
5.7M    libgfortran.so.4.0.0
5.8M    libTKGeomAlgo.so.7.4.0
6.0M    libscalapack.so
6.8M    libtsan.so.0.0.0
7.3M    libmpi.a
9.7M    gstreamer-1.0
9.8M    libasan.so.5.0.0
13M libstdc++.so.6.0.27
14M libChronoEngine.so
14M libLIEF.a
14M python3.7/lib-dynload
19M gcc
19M gcc/x86_64-conda_cos6-linux-gnu
19M libpetsc.so.3.12.4
24M libpython3.7m.nolto.a
26M libpython3.7m.a
27M libicudata.so.64.2
29M libopenblasp-r0.3.7.so
40M libclang.so
40M libclang.so.9
51M libopenblasp-r0.3.7.a
86M libLLVM-9.so
90M libQt5WebEngineCore.so.5.12.5
201M    libgmsh.so.4.5.3
292M    python3.7/site-packages
332M    python3.7