From 6f8401193a94c58504a1389c98824fa1bc9be6b1 Mon Sep 17 00:00:00 2001 From: Artak Vardanyan Date: Thu, 21 Dec 2023 15:28:00 +0000 Subject: [PATCH 1/3] Worlds smallest Docker Image - aka WSDI - pushing all hard work --- Dockerfile | 2 ++ README.md | 77 ++++++++++++++++++++++++++++++++++++++++++++++++++++-- d | 0 3 files changed, 77 insertions(+), 2 deletions(-) create mode 100644 Dockerfile create mode 100644 d diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..c8ffe09 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,2 @@ +FROM scratch +ADD d /d \ No newline at end of file diff --git a/README.md b/README.md index c9c899c..28ce4f8 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,75 @@ -# world-smallest-docker-image -The worlds smallest Docker image +# Worlds smallest Docker Image - aka WSDI + +Hi everyone, + +If you ever wondered what is the minimal Docker image in the world, then you are in right place. +Is it debian, is it alpine or busybox ? + +Our team at Dooqod did extensive research on to figure out this. + +We come up with 2 approaches to figure this out. + +## Approch 1: +At least there is finate amount of Docker images under DockerHub. +So this task should not be impossible. To run all of them and compare. + +But it'll take lots of time and resources. + +## Approach 2: +We decided to create the smallest one and publish under DockerHub. Sounds promising. + +## Wow moment +Wow, we can create the smallest Docker image in the wold. +It can be the MVP and we can try to sell it :) + +So we started this project right away. + +## Dockerfile of the 'worlds-smallest-docker-image' + +d - is just an emptyfile we add into 'scratch' + +```shell +FROM scratch +ADD d /d + +``` + +## What is scratch ? + +The scratch image is the most minimal image in DockerHub. This is the base ancestor for all other images. +The scratch image is actually empty. It doesn't contain any folders/files. + +You can use Docker’s reserved, minimal image, scratch, as a starting point for building containers. Using the scratch “image” signals to the build process that you want the next command in the Dockerfile to be the first filesystem layer in your image. + +While scratch appears in Docker’s repository on the hub, you can’t pull it, run it, or tag any image with the name scratch. Instead, you can refer to it in your Dockerfile. For example, to create a minimal container using scratch: + +https://hub.docker.com/_/scratch + +## How to build + +```shell +# just clone the repo +# cd into repository and run + +docker build -t wsdi Dockerfile . + +# or pull from DockerHub + +docker pull docker.io/dooqod/wsdi:latest + +# check + + +``` + +## Support the project to not grow :) + +Our goal is to make this image minimal. +We'll put all our efforts to keep it simple and small also in the feature. + + - Give a Github Star + - Buy cofee + + + + diff --git a/d b/d new file mode 100644 index 0000000..e69de29 From 1802e46dfcae0b3e2efc3810d00133498b89cb23 Mon Sep 17 00:00:00 2001 From: Artak Vardanyan Date: Thu, 21 Dec 2023 15:54:09 +0000 Subject: [PATCH 2/3] Pushed to Dockerhub, its showing 92 bytes under DockerHub. --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 28ce4f8..3f52786 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,6 @@ -# Worlds smallest Docker Image - aka WSDI +# Worlds smallest Docker Image - aka WSDI | 92 bytes + +https://hub.docker.com/repository/docker/dooqod/wsdi/general Hi everyone, @@ -51,7 +53,7 @@ https://hub.docker.com/_/scratch # just clone the repo # cd into repository and run -docker build -t wsdi Dockerfile . +docker build -t wsdi . # or pull from DockerHub From 41c58e30fbeab2cdfeb1a9eeaba27f88fa97dec5 Mon Sep 17 00:00:00 2001 From: Artak Vardanyan Date: Thu, 21 Dec 2023 16:14:31 +0000 Subject: [PATCH 3/3] readme typos fixed --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 3f52786..475048c 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,7 @@ But it'll take lots of time and resources. We decided to create the smallest one and publish under DockerHub. Sounds promising. ## Wow moment -Wow, we can create the smallest Docker image in the wold. +Wow, we can create the smallest Docker image in the world. It can be the MVP and we can try to sell it :) So we started this project right away. @@ -70,7 +70,7 @@ Our goal is to make this image minimal. We'll put all our efforts to keep it simple and small also in the feature. - Give a Github Star - - Buy cofee + - Buy lambo -