← All notes

Docker Build GitHub Actions: GitHub Builder and the individual Docker actions

Answer: Docker's GitHub Actions docs describe GitHub Builder reusable workflows for building and publishing images, plus individual actions when you need custom job steps.

GitHub Builder

GitHub Actions automates a build, test, and deployment pipeline. Docker GitHub Builder is a Docker-maintained reusable workflow that builds and publishes images.

The reusable workflow takes care of Buildx setup, platform distribution, metadata, and signing. Switch to individual actions when a job needs steps the reusable workflow does not expose.

Start with a GitHub repository that has a Dockerfile at its root, and a Docker Hub token that can push images.

Store the token as the DOCKERHUB_TOKEN secret and the username as the DOCKERHUB_USERNAME variable.

The sample workflow lives at .github/workflows/docker-ci.yml and calls docker/github-builder's build.yml. It pushes when the event is not a pull request.

set-meta-labels and set-meta-annotations apply generated labels and annotations. meta-images names the image.

When an image is pushed, GitHub Builder signs attestation manifests. The build uses the repository at the Git reference that triggered the run, so files changed in a caller job are omitted.

Individual actions

By default the build action takes a Git context, so BuildKit pulls the repo at the triggering Git reference. Use checkout with a path context when earlier steps change files the build needs.

Available actions include Build and push, Buildx Bake, Login, Setup Buildx, Metadata, Setup Compose, Setup Docker, Setup QEMU, and Scout.

The metadata action derives tags, labels, and annotations from Git and GitHub events. Setup QEMU supports multi-platform builds. Scout analyzes images for vulnerabilities.

See also

Claims

Sources

License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources: Docker, Inc., Docker Build GitHub Actions; Docker, Inc., Docker Build GitHub Actions (source). Apache-2.0 (https://raw.githubusercontent.com/docker/docs/main/LICENSE). Copyright Docker, Inc. Text was condensed and changed from the originals.

License: CC-BY-4.0 · Summary by iinventedlight (AI-assisted). Sources: Docker, Inc., Docker Build GitHub Actions; Docker, Inc., Docker Build GitHub Actions (source). Apache-2.0 (https://raw.githubusercontent.com/docker/docs/main/LICENSE). Copyright Docker, Inc.

Cite this

Permanent ID: iil:note:kbwyegea

iinventedlight. 2026. "Docker Build GitHub Actions: GitHub Builder and the individual Docker actions." iinventedlight Library, iil:note:kbwyegea, version of 2026-11-27. https://iinventedlight.com/library/notes/docker-build-github-actions/. License: CC-BY-4.0.

@misc{iil_note_kbwyegea,
  author = {{iinventedlight}},
  title = {{Docker Build GitHub Actions: GitHub Builder and the individual Docker actions}},
  howpublished = {iinventedlight Library},
  year = {2026},
  date = {2026-11-27},
  url = {https://iinventedlight.com/library/notes/docker-build-github-actions/},
  note = {Permanent ID iil:note:kbwyegea. License: CC-BY-4.0.},
}

Markdown

Spotted a mistake? Use the MCP feedback tool or email hello@iinventedlight.com. Or Report a correction (no account needed).

Extra files beside this note

These files use this note's license, shown below. Paper extras retain their reproduction status; a link is not a reproduction.

All artifact files (JSON index)

For language models and agents: start at /llms.txt | /agents.md | /.well-known/agent-library.json. This page in Markdown: /library/notes/docker-build-github-actions.md.