News for hackers. Stuff that matters.
Re:PHP Docker image just hit 1B pulls on Docker Hub by hiatus on Wednesday December 11, 2024 @10:01AM (#42388398)
> Also, containers build on other containers. E.g. the highly popular phpmyadmin or nextcloud images build on top of php. So each "nextcloud" pull, will result in a pull for php too. Are those developers? Does that mean hundreds of millions less pulls?

When pulling images from dockerhub that are based on other images, the image is rebuilt from scratch each time? That doesn't sound right.

Re:PHP Docker image just hit 1B pulls on Docker Hub by 0points on Wednesday December 11, 2024 @10:05AM (#42388446)
> the image is rebuilt from scratch each time?

That's not what parent is saying.

A Dockerfile usually start off with a base image, like:

    FROM php
This will pull the php base image, which is already built and published, from dockerhub.

I guess this makes sense if you are familiar with Docker.

Re:PHP Docker image just hit 1B pulls on Docker Hub by hiatus on Wednesday December 11, 2024 @06:05PM (#42394041)
Yeah but the dockerfile that builds the wordpress image or whatever is not being recreated/rebuilt with every pull of wordpress.
Re:PHP Docker image just hit 1B pulls on Docker Hub by 0points on Saturday December 14, 2024 @10:26AM (#42417659)
Yes, you seem to be grasping this.
Re:PHP Docker image just hit 1B pulls on Docker Hub by shagie on Wednesday December 11, 2024 @10:06AM (#42388459)
Layers are pulled.

If foolang image has:

    layer c
    layer d
    layer e
And then fooadmin image is FROM foolang:latest (and the more stuff) and builds the layers:

    layer f
    layer g
... then a user pulling fooadmin pulls layers g,f,e,d,c,b,a (b and a being layers provided by the image that foolang was built on top of).

The question is then "does the pull of layer e in docker pull foo admin count as part of docker pull foolang?"

Re:PHP Docker image just hit 1B pulls on Docker Hub by hiatus on Wednesday December 11, 2024 @06:07PM (#42394057)
> The question is then "does the pull of layer e in docker pull foo admin count as part of docker pull foolang?"

It doesn't.