It might be helpful to create a container that has nothing. Nothing means nothing.
Use case
In this answer https://stackoverflow.com/a/55683656/1315009 a container is created without ever starting it just to instantiate a volume and copy contents into the volume. Then the container is removed.
The example instantiates a busybox
. Nevertheless the busybox
contents are never used. So I tested it with the hello-world
and it works as well, thus reducing from 1.22MB to 13.3kB.
At the time being, pulling "scratch" fails:
$ docker pull scratch
Using default tag: latest
Error response from daemon: 'scratch' is a reserved name
So... Question
How can I create a container with an image that has "nothing" inside?
I mean similar to docker create hello-world
but without the hello-world
binary.