Registry
In one line
A registry is a storage and distribution service for container images and build artifacts.
In simple words
A registry is a server that stores and distributes container images (and other artifacts). It is where you push images after building them, and where you pull images from when deploying.
Popular registries include Docker Hub (public, free for public images), Amazon ECR (AWS), Google Container Registry / Artifact Registry (GCP), and GitHub Container Registry. You can also run a private registry using the open-source Docker Distribution or tools like Harbor.
Registries version images using tags (e.g., myapp:1.2.3, myapp:latest). They also provide access control, so you can control who can push and pull images. Many registries also scan images for security vulnerabilities.
Example
# Tag an image for a registry
docker tag myapp:1.0 registry.example.com/myapp:1.0
# Push to the registry
docker push registry.example.com/myapp:1.0
# Pull from the registry
docker pull registry.example.com/myapp:1.0Tag the image with the registry URL, push it to store it, and pull it to retrieve it on another machine.
How it works
- You build an image and tag it with the registry URL.
docker pushuploads the image to the registry.docker pulldownloads the image from the registry.- The registry stores layers and provides versioning via tags.
Common confusions
Confused with: Repository
The difference: A registry is the server that stores images; a repository (in Docker context) is a named collection of tagged images within a registry.
Related terms
Decode error messages
Plain-English explanations of common errors — what they mean, why they happen, and how to fix them.