dynamic-link and no-build targets use a trivial copy all from /opt, leading to unused modules and unused build artifacts to be copied to the resulting IOC image.
Any level of pruning could easily and greatly improve the final image size.
list of used modules taken from original RELEASE file before it's replaced
prune directories at the /opt/modules and /opt/modules/areaDetector levels when they don't appear in lddoutput for all executables/libraries in IOC / final directory (for no-build mode)
dynamic-link
andno-build
targets use a trivial copy all from/opt
, leading to unused modules and unused build artifacts to be copied to the resulting IOC image.Any level of pruning could easily and greatly improve the final image size.
_Discussion started by @ericonr in https://github.com/cnpem/epics-in-docker/pull/15#discussion_r1314850489_