Chapter Eleven

GitHub Actions in Depth

The patterns that turn Actions from a single workflow file into real CI/CD — matrices, caching, secrets, environments, reusable units, and the runners jobs execute on.

7 topics

The fundamentals chapter covered what a workflow, job, step, and trigger are. This one is about using them well: building a CI pipeline that actually blocks bad merges, fanning a job across a matrix of platforms, moving files across the ephemeral-VM boundary with caches and artifacts, and handling secrets so they never end up in a log.

From there it climbs to delivery — environments with approval gates that turn CI into controlled CD, reusable workflows and composite actions that kill copy-pasted YAML, and the self-hosted runners you reach for only when specific hardware or a private network demands it. Each topic is a decision you will make on real pipelines, with the failure modes that make the wrong choice expensive.

From CI gate to gated deploy
PR checksrequired
→
Build oncethen test
→
Deploy stagingon merge
→
Deploy productiongated

Topics in This Chapter