Closed chairfield closed 8 years ago
Hey, thank you for that interesting stat. It's a good idea to make this image a bit smaller.
Debians container is smaller because (among other things) less (more or less) essential dependencies are installed. That results in more dependencies pulled in by latex.
It's hard to tell the difference because repositories differ too.
I isolated the dependency difference between debian and ubuntu: Added only by ubuntu: https://gist.github.com/blang/5e9ad7d180d58b2c6712 Added only by debian: https://gist.github.com/blang/482d3920fd1fce3df2aa
The biggest difference (debian):
Package | Size |
---|---|
texlive-lang-korean | 40525052 |
texlive-lang-chinese | 30793488 |
texlive-lang-japanese | 8116072 |
libllvm3.5 | 7606578 |
cpp-4.9 | 5168834 |
libqtgui4 | 4189190 |
mupdf | 3420730 |
libruby2.1 | 3276844 |
perl | 2629342 |
perl-modules | 2551450 |
You can remove packages like mupdf (pdf viewer, useless inside docker) or korean language packages. You might also save space by removing package file after installation.
Thanks Benedikt. I was able to shave off some of the size of the debian image, but not enough to beat your ubuntu one. Further discussion would be in the realm of configuring LaTeX itself, and not your container.
For the record, I believe a serious opportunity to save space exists in the 1.5 GB of documentation texlive-full installs. I believe passing --no-install-recommends
to apt-get during the install will exclude most/all of it, but I have not verified this. As I do not understand the additional ramifications of doing so, I'll close the issue without any PR.
Thanks for helping me experiment with Docker!
Hello,
I'm just getting into Docker and I thought I would be able to optimize the size of your LaTeX image, but to no avail; even though
debian:latest
is 2/3 the size ofubuntu:trusty
(shaving off about 60 MB), the resultingdebian:latest
-based image is a whopping 300 MB larger! To satisfy my curiosity, would you happen to know why?Thanks for your work building this excellent repo.