HCPPipelines icon indicating copy to clipboard operation
HCPPipelines copied to clipboard

Reduce the size of the Docker image

Open pvelasco opened this issue 4 years ago • 0 comments

Hi,

The size of the Docker image pulled from Docker hub is huge, since it contains FSL, FreeSurfer, etc. However, as far as I can tell, there are many, many files from those distributions that are not used by the pipelines.

By deleting a lot of unused files and staging the building of the Docker image, I have managed to reduce the image size from 26.9 GB to 9.1 GB. A smaller Docker image not only means that you save disk space, but it also means a faster launching of a new container.

I have tested it on some datasets, but it could be (although I think it is unlikely) that running it on other datasets, because their peculiarities, will fail because of the files I removed from the Docker image.

So my questions are:

  1. Would you be interested in reducing the image size
  2. If so, do you have a test dataset to check my image, or could you check it against your test dataset? You can pull my image from DockerHub: docker pull cbinyu/bids_hcppipelines:latest After running the tests I could start a pull request incorporating my changes.

pvelasco avatar Nov 19 '20 18:11 pvelasco