A Docker image serves as a foundational blueprint for a container. It is the starting point for everything in Docker.
When you instruct Docker to create a container from an image using the docker run
command, Docker performs various operations such as setting up the file system and initializing dependencies to create the container.
Images are constructed using a Dockerfile, which can be processed using the docker build
command. These images can be stored locally or published on Docker Hub, a Docker registry. Docker Hub is a platform where developers can store and access both public and private Docker images.
On Docker Hub (https://hub.docker.com/), you will find a wide range of images that you can freely utilize without having to build your own. These images are often official, created by the development teams responsible for specific technologies.
For instance, the official Node.js Docker Image can be found at: https://registry.hub.docker.com/_/node.
In the upcoming sections, we will dive deeper into how to effectively use Docker images and containers.