GoogleContainerTools / distroless

🥑 Language focused docker images, minus the operating system.
Apache License 2.0
18.91k stars 1.16k forks source link

Misleading claim in README.md? #1482

Closed hulkish closed 10 months ago

hulkish commented 10 months ago

In the README.md of this project, it claims:

Distroless images are very small. The smallest distroless image, gcr.io/distroless/static-debian11, is around 2 MiB. That's about 50% of the size of alpine (~5 MiB), and less than 2% of the size of debian (124 MiB).

However, with a few commands this proves false:

$ docker pull node:20-alpine3.19
[...]
$ docker pull gcr.io/distroless/nodejs20-debian12:latest
[...]
$ docker images
REPOSITORY                            TAG             IMAGE ID       CREATED      SIZE
node                                  20-alpine3.19   a19a63a9d2e8   2 days ago   135MB
gcr.io/distroless/nodejs20-debian12   latest          7f4c94da2e88   N/A          181MB

So, this actually suggests that alpine impl of node is about 29% smaller than distroless impl of node. I understand that the above statement is accurate.... however it is misleading because in implementation - alpine in this case is actually smaller.

Am I missing something here?

loosebazooka commented 10 months ago

This claim is specifically about the static images. But also this claim has not been verified in many years. If you find that distroless/static isn't smaller than alpines smallest image, then sure we can update the README. Please re-open if you feel this needs an update.

hulkish commented 10 months ago

This claim is specifically about the static images. But also this claim has not been verified in many years. If you find that distroless/static isn't smaller than alpines smallest image, then sure we can update the README. Please re-open if you feel this needs an update.

I just think that if a comparison statement is being made... then it should be more revealing and elaborate that it is not always consequently smaller, as detailed above