YAML in GitHub Actions: Workflow Syntax, Triggers, and Gotchas
Write GitHub Actions YAML workflows: understand on triggers, jobs, steps, expressions, and common indentation errors that break pipelines.
Published:
Tags: yaml, github-actions, ci-cd
YAML in GitHub Actions: Workflow Syntax, Triggers, and Gotchas GitHub Actions workflows are YAML files that GitHub's runner interprets to execute CI/CD pipelines. The YAML schema is GitHub-specific — it's not Kubernetes, not Docker Compose, not Ansible. Understanding what each field does and where the YAML parser trips you up prevents the most common category of CI failures: the workflow that never runs, the step that always fails before executing, and the variable that's empty when it shouldn't be. Minimal Valid Workflow Every workflow needs: — what triggers it — one or more named jobs Each job needs and --- Triggers The field determines when the workflow runs. It's one of the most misunderstood fields because it has several forms. Simple Event Triggers Filtered Push and Pull Request…
All articles · theproductguy.in