Registry, CI & Deploy — Module Overview
What is a container registry?
Section titled “What is a container registry?”Once you have built a Docker image it lives only on your machine. A registry is a server that stores and distributes images so that other machines — a CI runner, a cloud server, a colleague’s laptop — can pull and run exactly the same image.
The workflow is always the same three steps:
Build → Tag → Push (your machine / CI runner) ↓ Registry ↓ Pull → Run (deployment server)Every step maps to a Docker command you already know (or will learn in this module):
docker build -t myapp:1.0 .docker tag myapp:1.0 docker.io/acme/myapp:1.0docker push docker.io/acme/myapp:1.0# --- on the server ---docker pull docker.io/acme/myapp:1.0docker run -d docker.io/acme/myapp:1.0Docker Hub vs other registries
Section titled “Docker Hub vs other registries”| Registry | Address | Notes |
|---|---|---|
| Docker Hub | docker.io (default) | Largest public registry; free public repos |
| GHCR | ghcr.io | GitHub Container Registry; integrated with GitHub Actions |
| ECR | *.dkr.ecr.*.amazonaws.com | AWS-native; IAM auth |
| GAR | *.pkg.dev | Google Artifact Registry |
| Self-hosted | Any host | Run registry:2 yourself |
When no registry address is specified, Docker defaults to docker.io. The snippet FROM node:22-alpine is shorthand for FROM docker.io/library/node:22-alpine.
What this module covers
Section titled “What this module covers”| Lesson | What you will learn |
|---|---|
| This page | Registries, image distribution workflow, Docker Hub vs alternatives |
| Docker Hub | Accounts, repos, public vs private, docker login, rate limits |
| Tag, Push & Pull | Naming convention, docker tag, docker push, docker pull, version tags |
| GitHub Actions CI | Automated build & push with docker/build-push-action |
| Deploy basics | docker run -d, --restart, rolling updates, secrets on the host |
Hands-on: pull and run a public image
Section titled “Hands-on: pull and run a public image”No credentials needed — any public image on Docker Hub can be pulled straight from Play with Docker. Try it now.
# Pull a public image from Docker Hub
docker pull docker.io/library/hello-world:latest
# Run it
docker run --rm hello-world
# Pull an nginx image and check the tag
docker pull nginx:1.27-alpine
docker images nginx