manuel-munoz-aguirre / PyHIST

A pipeline to segment tissue from the background in histological images
GNU General Public License v3.0
56 stars 13 forks source link

reduce docker image size by almost half #28

Open kaczmarj opened 2 years ago

kaczmarj commented 2 years ago

thank you for making this package -- it's exactly what i need :)

This commit substantially reduces the size of the docker image by using multi-stage builds. This allows us to build the software in the first stage and copy the built artifacts into the second, final stage. We only install runtime dependencies into the second stage. We also use a python base image so that python/pip are already available in the image.

vntasis commented 2 years ago

Hi

Thanks for the suggestion. It is useful. I merged your version, but afterwards I changed it mainly for maintenance purposes. Now we use the multi-stage build, but the environment inside the docker image will be build based on the conda yml file. The resulted image is a bit bigger than the one you suggested, but it will be better long term.

Vasilis