GitHub Actions
GitHub's built-in automation service that runs workflows, written as YAML files in a repository, on runners when events happen.
In more detail
A workflow file contains jobs, each job runs on its own runner, and each job is a list of steps that run a shell command or call a reusable action. Events such as a push or a pull request start workflows.
Examples
jobs:
plan:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: terraform plan -out=tfplanIn Terraform: The course's pipeline is a GitHub Actions workflow: it runs on pull requests and pushes to main, checks out the code, then runs terraform fmt, init, validate and plan. It is shown as a transcript because it only runs inside GitHub.In this course: Each job in a workflow can be made a required check on pull requests, which is how a quality gate is usually enforced on GitHub. Workflows are defined in YAML files in the repository's .github/workflows folder.Related terms
- workflow (GitHub Actions) — A YAML file in the .github/workflows folder of a repository that names its triggers and the jobs to run.
- job (GitHub Actions) — A named group of steps in a workflow that runs on one runner of its own.
- step (GitHub Actions) — One task inside a job, either a shell command under run or an action called with uses.
- action (GitHub Actions) — A reusable, published unit of automation that a workflow step calls with uses.
- runner — A machine running the runner application that picks up a queued job, runs its steps and reports the result.
- GitHub — A hosting service for Git repositories that adds collaboration features such as pull requests, issues, forks and releases.
- GITHUB_TOKEN — A short-lived access token GitHub creates for each job so the workflow can call the GitHub API for its own repository.
- workload identity — An identity for software rather than a person, proven by a signed token from the platform it runs on instead of a stored key.
- GitHub environment — A named deployment target in GitHub, such as production, that can require reviewers to approve before a job using it runs.
- continuous integration — Automatically building and testing every change as soon as it is pushed, so problems are caught early.
- pipeline — An automated sequence of steps, such as build, test, scan and publish, that runs on every change.
- docker buildx — The Docker command for advanced BuildKit features, such as building for several platforms or on remote builders.
- build cache — Saved results of earlier build steps that a build tool, such as Docker, reuses when nothing a step depends on has changed.
- YAML — A human-friendly text format for configuration, where indentation shows structure.
- pull request — A request on a hosting service such as GitHub to merge one branch into another, with a page for review, discussion and automated checks.
Taught in
- GitHub Actions And Azure Pipelines Side By Side — Microsoft Azure DevOps Engineer Expert (AZ-400) Exam Prep
- What Is a Pipeline? — Continuous Integration & Continuous Delivery Pipelines
- Runners: Where Code Executes — Continuous Integration & Continuous Delivery Pipelines
- Workflows, Jobs, Steps, and Actions — Continuous Integration & Continuous Delivery Pipelines
- Defining Environments in GitHub Actions — Continuous Integration & Continuous Delivery Pipelines
- AWS Organizations, Account Hierarchies & Azure Management Groups — Cloud Security & DevSecOps Engineering
- Cloud IAM Architecture & Permission Boundaries — Cloud Security & DevSecOps Engineering
- Least Privilege Enforcement & CIEM Architecture — Cloud Security & DevSecOps Engineering
- Shift-Left Security Principles & Automated Pipeline Gates — Cloud Security & DevSecOps Engineering
- Enforcing OPA Guardrails on Terraform Plan Payloads — Cloud Security & DevSecOps Engineering
- Cloud Security Posture Management & Remediation — Cloud Security & DevSecOps Engineering
- Continuous Integration — DevOps & Site Reliability Engineering
- Build, Test And Promote The Same Image In CI — Docker Architecture & Production Containers
- The Workflow That Ran On A Stranger's Pull Request — GitHub Actions (GH-200) Exam Prep
- How GH-200 Asks: Pacing, Weights And Stems — GitHub Actions (GH-200) Exam Prep
- Workflow Structure: Jobs, Env, Services, Commands And Anchors — GitHub Actions (GH-200) Exam Prep
- Expressions, Contexts And The If That Is Always True — GitHub Actions (GH-200) Exam Prep
- Governing Actions: Allow Lists, SHA Pinning And Rulesets — GitHub Actions (GH-200) Exam Prep
- GitHub-Hosted And Larger Runners: Specs, Software And Networks — GitHub Actions (GH-200) Exam Prep
- Self-Hosted Runners At Scale: Labels, Groups And ARC — GitHub Actions (GH-200) Exam Prep
- Secrets And Variables By Scope: Precedence, Access And The REST API — GitHub Actions (GH-200) Exam Prep
- Usage, Billing And The Audit Log — GitHub Actions (GH-200) Exam Prep
- GITHUB_TOKEN: Least Privilege, Job By Job — GitHub Actions (GH-200) Exam Prep
- Full Mock And Review: Where Your Points Go — GitHub Actions (GH-200) Exam Prep
- Running Terraform In CI — Infrastructure as Code with Terraform
- Native Testing With Tftest Files — Infrastructure as Code with Terraform
- Provider Mocking For Tests — Infrastructure as Code with Terraform
- Policy As Code With OPA — Infrastructure as Code with Terraform
- Releasing The Real Cloud Artifact — Infrastructure as Code with Terraform
- What To Automate Away — Automated Testing, TDD & Quality Engineering