4 ms·
you kinda lost me at this: "Docker images are big and contain full-blown operating systems as they are meant to run arbitrary applications" because it's exact
by ABS 11y ago
you kinda lost me at this:
"Docker images are big and contain full-blown operating systems as they are meant to run arbitrary applications"
because it's exactly how you are not supposed to use docker, you are supposed to include only what you need and you most definitely do not need a full operating system inside a container that runs on a full operating system.
back to Java: our base java docker images are around 70MB, see this to see how, I'm not involved in it: https://github.com/delitescere/docker-zulu https://github.com/delitescere/docker-zulu
Yes, still bigger than the uberjar but that's the not point
- pron 11y agoEven if you optimize or images and layer them in such a way that they share dependencies, you still need to create them, which is much slower than not creating them, and requires an extra tool, and requires handling management and logging less conveniently. You don't need Docker for containers, and the JVM has better packaging solutions than Docker. Why add an extra tool and an extra step for less convenience?
- ABS 11y agoyou are missing the point of my comment which is: your "Footprint" is factually wrong
- pron 11y agoI don't think so. For the same amount of work you get a much higher footprint. Want smaller footprint? Start grouping your dependencies into layers -- namely, extra work. When I say that something is higher footprint or worse performance etc., I mean that that's what you get for the same amount of work compared to your point of comparison, not that it's impossible to make it better if you work harder.
- ABS 11y agook but that's not what you wrote. I quoted verbatim what you wrote and it's not correct, Docker images do not "contain full-blown operating systems as they are meant to run arbitrary applications" unless you decide to put a full-blown operating systems in them but that's your choice, you definitely don't have to and everyone recommends not to
- pron 11y agoFair enough. Clarified in the post.