31 min readAI-assisted

Chapter Self-Check

Companion question bank for the 14-part tutorial series in this folder: 01-cicd-fundamentals.md, 02-infrastructure-as-code.md, 03-gitops.md, 04-github-actions.md, 05-github-security-governance.md, 06-gitlab-cicd.md, 07-bitbucket-pipelines.md, 08-azure-devops.md, 09-jenkins.md, 10-circleci.md, 11-tekton.md, 12-monorepo-cicd.md, 13-progressive-delivery.md, 14-self-hosted-runner-scaling.md.

Answers are short and plain — expand out loud using the diagrams and worked examples in the tutorials.


Part 1 Questions: CI/CD Fundamentals#

What is Continuous Integration, in one sentence?

Developers merge small code changes frequently, with an automated process building and testing every single merge immediately — shift-left applied to integration bugs.

Distinguish Continuous Delivery from Continuous Deployment.

Delivery: every change that passes CI is automatically made ready to deploy, but a human still decides when to actually release it. Deployment: that human gate is removed too — every passing change goes live automatically. Most real organizations practice Delivery, not full Deployment.

Why should pipeline stages run cheapest/fastest first?

So a broken build fails and reports back within seconds, not after waiting many minutes for a slow test suite to even start — the same "fail fast, cheap checks first" principle from the DevSecOps series' layered scanning pipeline.

Compare the four deployment strategies in one line each.

Recreate: stop everything old, then start everything new (causes downtime). Rolling: gradually replace instances, no downtime, but both versions briefly coexist. Blue-Green: two full environments, instant traffic switch and near-instant rollback, but double infrastructure cost. Canary: small % of traffic to the new version first, limiting blast radius.

Why is blue-green's rollback meaningfully faster than a rolling deployment's rollback?

Rolling back a blue-green switch just means flipping the router back to the still-running old environment — near-instant. Rolling back a rolling deployment means running the same gradual replacement process again in reverse, which takes real time proportional to fleet size.

Why does a canary deployment connect to the error budget concept?

By exposing only a small % of traffic to a risky change, a team deliberately spends a small, controlled sliver of error budget to validate it — rather than exposing 100% of users and burning a much larger chunk of budget to find the same bug.

What's the difference between a canary deployment and a feature flag?

A canary controls what % of traffic hits NEW CODE. A feature flag controls what % of traffic sees NEW BEHAVIOR, even within the exact same running code. They're complementary — you can canary-deploy code that itself contains a feature flag.

Why do feature flags matter for rollback risk specifically?

They decouple deploying code from releasing a feature — a bad feature can be disabled instantly by flipping a flag, with no new deploy (and none of a deploy's associated risk) needed at all.

Name the four DORA/Four Keys metrics.

Deployment Frequency, Lead Time for Changes, Change Failure Rate, Time to Restore Service.

What's DORA's counter-intuitive finding about speed vs. stability?

Elite performers are simultaneously fast (frequent deploys, short lead time) AND stable (low change failure rate, fast recovery) — speed and stability aren't actually a tradeoff at the organizational level, contradicting the instinct that "moving fast breaks things."


Part 2 Questions: Infrastructure as Code#

What problem does Infrastructure as Code solve?

It replaces manual, undocumented, click-through-the-console infrastructure changes with version-controlled, reviewable, auditable code — directly attacking the "toil" problem from the SRE Fundamentals series, applied to infrastructure.

Distinguish provisioning from configuration management, with example tools.

Provisioning creates the actual infrastructure itself (Terraform, CloudFormation). Configuration management configures what runs ON already-existing infrastructure (Ansible, Chef, Puppet).

What is idempotency, and why is it the single most important IaC property?

Running the same operation any number of times produces the same end result as running it once. It's what makes IaC safe to re-run after a failure or partial success — the exact same underlying philosophy as the Kubernetes reconciliation loop.

Why is terraform plan such an important safety step?

It's a dry run showing exactly what will be created, changed, or destroyed BEFORE anything actually happens — giving a human (or an automated policy gate) a chance to catch a mistake before it becomes real, potentially irreversible damage.

Why does losing the Terraform state file matter so much?

It's Terraform's only record connecting your code to the specific real resources it created. Without it, a re-run could create duplicate resources or fail to recognize existing ones — a small file with outsized, critical importance.

Why does Terraform need state locking, not just remote state?

Two simultaneous apply operations against the same unlocked shared state can write conflicting updates, corrupting it. Locking blocks a second apply until the first one completes and releases the lock.

What is drift, and what usually causes it?

Reality (the real infrastructure) no longer matching what the code/state believes it should be — usually caused by someone making a manual change directly in the cloud console, bypassing the IaC tool entirely.

What's the practical discipline for preventing drift with plain Terraform?

Treat the code as the sole source of truth and never make manual console changes to anything Terraform manages — every change goes through plan/review/apply. (GitOps, Part 3, enforces this even more strictly and automatically.)

Why are Terraform and Ansible often used together rather than as substitutes?

They solve genuinely different jobs — Terraform provisions the infrastructure (the VM, the network), Ansible configures what runs on it once it exists. A common pattern: Terraform creates the servers, Ansible configures them.

Is Ansible agent-based or agentless, and why does that matter?

Agentless — it connects over standard SSH and runs remotely, with no permanent agent software needing to be pre-installed on target servers, a real, distinctive difference from some other configuration management tools.


Part 3 Questions: GitOps#

What's the core idea that distinguishes GitOps from "just using IaC"?

Git becomes the single, ENFORCED source of truth, with a dedicated tool continuously and automatically reconciling actual state to match it — not just "infrastructure is defined in code," but a tool actively, continuously enforcing that the code IS what's running.

Name the four GitOps principles.

Declarative, versioned and immutable (stored in Git), pulled automatically (agents pull, rather than being pushed to), continuously reconciled.

What's the difference between push-based and pull-based deployment?

Push: an external CI pipeline actively pushes changes to the cluster, holding standing production credentials to do so. Pull: an agent running INSIDE the cluster continuously watches Git and applies changes itself — nothing external needs any credentials to modify the cluster.

Why is the pull-based model considered more secure, tied to a real-world incident?

It eliminates the need for any external system (like a CI pipeline) to hold standing production write credentials — directly reducing the exact class of supply-chain attack surface that enabled the SolarWinds incident, where a compromised build system had a direct path to modify what customers trusted.

What are ArgoCD and Flux, and what do they have in common?

The two dominant GitOps tools for Kubernetes, both CNCF projects implementing the same core reconciliation principles — continuously comparing Git's desired state against the live cluster and converging any difference.

What do ArgoCD's prune: true and selfHeal: true settings actually do?

prune: if something is removed from Git, it gets deleted from the real cluster too. selfHeal: if someone manually changes something directly in the cluster (drift), it's automatically reverted back to match Git on the next reconciliation pass.

How does GitOps's self-healing improve on plain Terraform's drift-prevention approach?

Plain Terraform relies on team DISCIPLINE — everyone consistently choosing to go through code, never the console. GitOps self-healing is AUTOMATICALLY, CONTINUOUSLY enforced by the tool itself, not just relied upon from every individual engineer.

How does multi-environment promotion typically work in a GitOps workflow?

It's just a Git commit/PR updating a value (like an image tag) in the target environment's directory — fully auditable, fully reversible, requiring no special tooling beyond Git and the GitOps agent already watching the repo.

Why do secrets create a genuine tension with GitOps's "everything in Git" principle, and how is it resolved?

Git is fundamentally the wrong place for raw secrets (deleting one doesn't remove it from history). Resolved via Sealed Secrets (the value is encrypted before committing, decryptable only by the target cluster) or External Secrets Operator (Git stores only a reference/pointer; the actual value is fetched live from a real secrets manager like Vault).

How does a rollback work in GitOps, and why is that a strong answer?

git revert on the bad commit — the GitOps agent sees the reverted commit as the new desired state and automatically reconciles the cluster back to the previous, known-good configuration. It's strong because it reuses the exact same, already-trusted mechanism (Git history) as every other change, with no special rollback tooling needed.

Why does GitOps give a strong disaster recovery story "almost for free"?

Since Git already is the complete, declarative source of truth for everything that should exist, recovering from a total cluster loss is just pointing a brand-new cluster's agent at the same repo — the same reconciliation loop that handles everyday drift correction does the entire rebuild automatically.


Part 4 Questions: GitHub & GitHub Actions#

What's structurally different about how GitHub Actions relates to GitHub, versus a bolted-on CI tool like Jenkins?

The pipeline definition lives in the same repository as the code, at .github/workflows/, triggered natively by events GitHub already tracks (push, PR, release) — no separate system, no webhook plumbing, and pipeline changes are reviewed in the same PR as the code they build.

Distinguish a composite action from a reusable workflow.

A composite action reuses a sequence of steps within a job (no runs-on of its own). A reusable workflow reuses one or more entire jobs, including their own runner and matrix, invoked via uses: at the job level with workflow_call.

Why does fail-fast: false matter for a compatibility matrix specifically?

The default (true) cancels every other matrix combination the instant any one fails, potentially hiding results from combinations that would have shown a different, independently useful failure — false lets every leg finish so the full compatibility picture is visible.

What's the difference between a cache and an artifact in GitHub Actions?

A cache speeds up future runs (best-effort, may be evicted) — typically dependencies. An artifact passes data between jobs or preserves a build output, with a guaranteed retention window — never rely on cache for anything correctness-critical.

How does a GitHub Environment implement the Continuous Delivery vs. Continuous Deployment distinction from Part 1?

A workflow is Continuous Deployment by default (fully automatic). Adding required reviewers to the target Environment turns it into Continuous Delivery — the pipeline still gets a build all the way to deployable, but a human must approve the final release step.

Why is a self-hosted runner risky on a public repository's default PR trigger?

Anyone can open a pull request; if a workflow using a self-hosted runner runs on pull_request, an external contributor's code can execute directly on the organization's own infrastructure.


Part 5 Questions: GitHub Security & Governance#

Why should GITHUB_TOKEN default to contents: read at the workflow level?

Least privilege — a compromised dependency pulled in during the job inherits only what the token can do; escalating specific scopes only in the specific job that needs them limits the blast radius of a supply-chain compromise.

Why is pinning a third-party Action to a commit SHA safer than pinning to a tag like @v4?

A tag is mutable — the maintainer (or an attacker who compromises them) can move it to point at different code with no review. A commit SHA is immutable by Git's own design, guaranteeing the exact same code runs every time until deliberately bumped.

In one sentence, what does OIDC replace, and why is that categorically safer?

It replaces a long-lived, stored cloud credential with a short-lived signed token minted fresh per run — a leaked OIDC-derived credential expires in about an hour and cannot be regenerated by an attacker, versus a leaked static key valid until manually rotated.

What's the pull_request_target trap, precisely?

Using pull_request_target (which grants the base repo's write-capable token) while also checking out and executing the PR's own untrusted head branch code — letting an external contributor's code run with elevated, real credentials.

What's the single highest-leverage GitHub Advanced Security feature to enable first, and why?

Secret scanning push protection — it blocks a secret at the cheapest possible point (before it's ever accepted into Git history), avoiding the painful history-rewrite cleanup required once a secret is already committed and pushed.

What does a build provenance attestation prove that SHA-pinning and OIDC alone don't?

That a specific artifact sitting in a registry right now was actually produced by the real pipeline, from the real source — closing the gap where someone with registry write access could swap an image after the fact, verified independently at deploy time.


Part 6 Questions: GitLab & GitLab CI/CD#

What's GitLab's core platform philosophy, and how does it differ from GitHub's?

GitLab markets itself as one integrated DevOps platform (planning, SCM, CI/CD, security scanning, registry, all one product) rather than a git host with CI/CD as one feature — shown concretely in how close to free built-in security scanning is versus GitHub's more ecosystem-driven, opt-in model.

Why do GitLab pipelines need needs: to become a genuine DAG, when GitHub jobs are parallel by default?

GitLab's default is strictly stage-sequential — every job in one stage waits for the entire previous stage to finish. needs: lets a specific job start as soon as its actual dependencies finish, regardless of stage, avoiding wasted wall-clock time.

Distinguish workflow:rules: from a job's own rules:.

workflow:rules: decides whether the entire pipeline is created at all for a given event. A job's own rules: then decides whether that specific job runs within a pipeline that already exists — a job never runs if the pipeline itself was never created, regardless of its own rules.

What problem do merge trains solve that ordinary "require passing CI before merge" doesn't?

At high merge volume, several other MRs can land between an MR's last passing pipeline and its actual merge, silently invalidating that test run. A merge train tests each MR against a simulated state including every MR ahead of it in the queue, guaranteeing the tested state matches the actual merge state.

What makes a GitLab compliance pipeline a genuinely stronger governance guarantee than a required CI check?

It's injected centrally at the group/framework level — an individual project maintainer cannot remove or bypass it even with full admin rights over their own .gitlab-ci.yml, unlike a required status check whose defining workflow file a maintainer could simply delete.

What's Auto DevOps, and what's its realistic sweet spot?

A zero-configuration, auto-generated full pipeline (build/test/scan/deploy) for a conventionally-structured app deploying to Kubernetes. It's most valuable as a fast on-ramp for new projects, progressively overridable — not a universal fit for a bespoke or legacy release process.


Part 7 Questions: Bitbucket & Bitbucket Pipelines#

What's Bitbucket Pipelines' single strongest, most distinctive feature, and why is it hard to replicate elsewhere?

Native Jira integration — Smart Commits and automatic deployment tracking surface directly on a linked Jira issue with zero separate integration tooling, because both products are built by the same vendor specifically to interlock, unlike a third-party GitHub/GitLab-Jira integration.

What does default: vs. a matched branches: entry mean when both exist for a push to main?

The most specific match replaces, not supplements — a push to main matching an explicit branches: { main: ... } entry runs only that pipeline definition, never default: in addition.

Name two genuine capability gaps in Bitbucket Pipelines versus GitHub Actions and GitLab CI/CD.

No native matrix-build primitive (parallel steps must be hand-written), and a materially thinner built-in security-scanning story (mostly assembled from third-party Pipes rather than near-one-line built-in templates).

What's a Pipe, and how does it compare to a GitHub Action or GitLab CI/CD Component?

A focused, single-purpose packaged integration (deploy to AWS, post to Slack) — narrower in scope than a GitHub Action or GitLab Component, which can define arbitrary multi-step reusable job logic; Bitbucket has no first-party equivalent of a cross-repo reusable custom pipeline.

What does the Protected flag on a Bitbucket repository variable actually control?

Whether the variable is visible only to pipelines running on a protected branch/tag, versus visible to a pipeline on any branch — the same least-privilege secrets-scoping principle as GitHub Environment secrets and GitLab Protected variables, as a single checkbox.


Part 8 Questions: Azure DevOps#

What structurally distinguishes Azure Pipelines from every other platform in this series?

It can build and deploy from any Git repository — Azure Repos, GitHub, GitLab, Bitbucket, or a generic Git server — not only its own repo hosting; "using Azure DevOps" and "using Azure Repos" are two independent decisions.

Why should new pipelines use YAML Pipelines rather than Classic Pipelines?

Classic Pipelines are pure UI/database configuration outside version control, invisible to code review — the exact problem CI/CD-as-code exists to solve. YAML Pipelines are checked into the repo and reviewed in the same PR as the code they build.

Distinguish template: from extends: as Azure's two reusability mechanisms.

template: is opt-in composition — the calling pipeline still fully controls its own structure and can skip or reorder around it. extends: inverts control — the template defines the overall pipeline structure, and the caller can only fill in exposed parameter slots, making it structurally non-bypassable.

What's a pipeline decorator, and how is it stronger than an extends: template for governance?

An organization-level extension that injects steps into every pipeline automatically, with zero reference required from any individual pipeline file — stronger than extends: because extends: still requires the pipeline author to use it in the first place.

Why is Azure DevOps's OIDC setup often described as lower-friction than GitHub's or GitLab's?

A Service Connection configured with Workload Identity Federation handles the trust relationship through a largely automatic, portal-driven setup, and the pipeline YAML needs no explicit permissions:/id_tokens: declaration — the complexity is absorbed into the Service Connection abstraction.

What do Azure's native rolling and canary deployment strategies provide that the other three platforms in this series lack?

A first-class, structured deployment-strategy primitive (named phases like preDeploy/deploy/routeTraffic, plus on: failure:/on: success: hooks) directly in the pipeline YAML — on GitHub, GitLab, and Bitbucket, an equivalent rollout has to be hand-authored as ordinary script steps or delegated entirely to the deployment target.


Part 9 Questions: Jenkins#

Why has Jenkins remained relevant into 2026 despite SaaS CI/CD platforms dominating new adoption?

Its self-hosted, fully open, plugin-extensible model still fits organizations with hard on-prem/air-gapped requirements or a large legacy investment — the tradeoff this series has repeated throughout: self-hosted flexibility against the operational burden of running the platform yourself.

Distinguish Jenkins's controller from its agents.

The controller schedules jobs, serves the UI, and holds configuration/plugin state; agents are the actual machines (static, Docker, or dynamic Kubernetes Pods) that execute a pipeline's steps — the controller never runs build work itself in a properly hardened setup.

Why did Declarative Pipeline replace Freestyle jobs as the recommended way to define a Jenkins job?

Freestyle jobs are UI/database configuration, invisible to code review — the same CI/CD-as-code problem Classic Pipelines have in Azure DevOps. A Jenkinsfile is checked into the repo, reviewed in the same PR as the code it builds.

What problem does a Jenkins Shared Library solve?

Reusable pipeline logic (steps, functions, even whole stage definitions) versioned in its own repo and imported with @Library, avoiding copy-pasted Jenkinsfile logic across many repositories — Jenkins's own answer to GitHub reusable workflows or GitLab CI/CD Components.

How do dynamic Kubernetes agents (pod templates) differ from a static agent pool?

A static pool is fixed-size, always-on VMs — the same idle-cost problem this series' Part 14 argues against. Kubernetes pod-template agents are provisioned per-build and torn down after, giving Jenkins the same scale-to-zero property as ARC or GitLab's Kubernetes executor.

What does Jenkins Configuration as Code (JCasC) solve?

Jenkins's own controller-level settings (security realm, credentials stores, plugin configuration) historically lived only in UI-driven, undiffable XML state; JCasC expresses that configuration as version-controlled YAML, extending pipeline-as-code discipline to the controller itself, not just individual jobs.

Name one concrete Jenkins security hardening practice covered in this chapter.

Enabling CSRF protection (crumb issuer), enforcing matrix-based RBAC instead of the legacy "logged-in users can do anything" default, and running the Groovy sandbox/Script Security plugin to prevent arbitrary unapproved script execution.

What's the single biggest operational risk of Jenkins's plugin ecosystem?

Its scale and age are also its liability — thousands of community-maintained plugins of wildly varying maintenance quality, each a potential supply-chain and security surface, unlike a SaaS platform's own tightly curated, vendor-maintained integration set.


Part 10 Questions: CircleCI#

What pricing model differentiates CircleCI from GitHub Actions' or GitLab's per-minute billing?

Compute credits, consumed at different rates depending on the executor's resource class (a larger machine consumes credits faster than a small one) — a more granular cost model than a flat per-minute rate.

Distinguish a CircleCI job from a workflow.

A job is one unit of work running in one executor; a workflow orchestrates multiple jobs together via requires: dependencies, fan-out/fan-in, and approval gates — the same job/pipeline separation this series has covered per-platform throughout.

What's CircleCI's reusability mechanism, and its GitHub/GitLab equivalent?

Orbs — shareable, versioned packages of jobs, commands, and executors, published to a registry — functionally parallel to GitHub reusable workflows/composite actions or GitLab CI/CD Components.

What are CircleCI Contexts used for?

Sharing a named set of secrets/environment variables across multiple projects without duplicating them per-project — access is restricted by security group membership, similar in spirit to GitHub/GitLab's org-level secret scoping.

How does CircleCI implement OIDC to eliminate long-lived cloud credentials?

CircleCI issues a short-lived, cryptographically signed OIDC token per job that a cloud IAM trust policy verifies before granting temporary credentials — the same trust-without-long-lived-secrets pattern already covered for GitHub, GitLab, and Azure DevOps earlier in this series.

What's CircleCI's standout capability for large test suites?

Parallelism combined with intelligent test splitting — CircleCI's own timing data from prior runs is used to divide a test suite across parallel containers so each finishes in roughly the same wall-clock time, rather than a naive even-count split.

How does CircleCI's self-hosted runner model differ architecturally from GitHub's ARC or GitLab's Kubernetes executor?

It's built around a long-running agent process polling for jobs, not a Kubernetes-native, ephemeral-Pod-per-job controller — a genuine architectural difference (covered in Part 14's platform comparison), not simply a feature gap CircleCI is expected to close over time.

What do Docker Layer Caching and Remote Docker provide?

A way to reuse previously built Docker image layers across CI runs and to build/run Docker containers from within a job even when the executor itself isn't a Docker-native environment — directly speeding up container-heavy pipelines.


Part 11 Questions: Tekton#

What's fundamentally different about Tekton compared to every other platform in this series?

It's a set of Kubernetes-native building-block primitives (CRDs), not a finished platform — there's no built-in UI-driven job definition, no vendor SaaS; a team assembles Tekton into a CI/CD system rather than adopting one, the explicit build-vs-buy tradeoff this chapter frames directly.

Define Task, TaskRun, Pipeline, and PipelineRun.

A Task is a reusable definition of steps; a TaskRun is one actual execution of a Task. A Pipeline composes multiple Tasks into a DAG; a PipelineRun is one actual execution of that Pipeline — the same definition/execution split at both the single-unit and composed levels.

Why does every Step in a Tekton Task run in its own container?

Strong isolation between steps by design — unlike a Jenkins stage's shared shell environment, each Step is a genuinely separate container, sharing state only through explicit Workspaces, not ambient filesystem/environment leakage between steps.

What is a Tekton Workspace?

The explicit mechanism for sharing data (source code, build artifacts, caches) between Tasks in a Pipeline, since Tasks otherwise run in fully isolated containers with no implicit shared state.

What problem do Tekton Chains solve?

Automatic supply-chain attestation — Chains observes completed TaskRuns and generates in-toto/SLSA-format provenance attestations without requiring the Pipeline author to add attestation steps manually, directly supporting the DevSecOps series' SLSA coverage.

What is Tekton Triggers for?

Turning incoming webhooks (a GitHub push, a GitLab merge event) into new PipelineRuns automatically — Tekton's core primitives have no built-in event-listening mechanism of their own, so Triggers is the component that closes that gap.

How does Tekton achieve container image builds without privileged access?

Using Kaniko (or an equivalent rootless builder) inside a Task step, which builds an OCI image entirely in user space without requiring Docker-in-Docker or a privileged container — a meaningfully stronger security posture than mounting the host's Docker socket.

What's a StepAction?

A reusable Step definition that can be shared across multiple Tasks, similar in spirit to a small, focused function — finer-grained reuse than sharing a whole Task, useful when only one step's logic (not an entire Task) needs to be shared.

How does Tekton compare to Argo Workflows?

Both are Kubernetes-native, CRD-based pipeline engines with genuine overlap; Tekton is more CI/CD-purpose-built (SCM triggers, image-build-focused primitives via Chains/Hub), while Argo Workflows leans more general-purpose DAG/data-pipeline orchestration — the choice usually comes down to which ecosystem's other tools (Argo CD, Argo Rollouts) a team is already standardized on.


Part 12 Questions: Monorepo CI/CD Strategies#

Why is monorepo CI/CD a genuinely different problem from polyrepo CI/CD, not just "the same thing at bigger scale"?

A single push can touch code belonging to many independently deployable services at once, so "build and test everything on every push" becomes prohibitively slow at scale — the core problem this chapter's tooling (affected-only builds, remote caching) exists to solve.

What's the ceiling of path-based filtering alone?

It only sees which files literally changed, not which services actually depend on those files transitively — a shared library change won't correctly trigger every consumer's build unless the filtering tool understands the real dependency graph, which plain path filtering doesn't.

Distinguish Nx's affected detection from Turborepo's task pipeline model.

Nx builds an explicit project graph and computes nx affected from real dependency relationships; Turborepo defines task pipelines (build depends on upstream builds) and layers a remote cache on top — both solve affected-only execution, with different graph-construction philosophies (inferred vs. declared).

What does Bazel provide that Nx and Turborepo don't?

Fully hermetic, reproducible builds — Bazel sandboxes every build action so it cannot silently depend on unstated inputs, at real setup-cost expense; Nx/Turborepo optimize an existing JS/TS toolchain rather than replacing the build model itself.

What's the real force multiplier of remote caching in a monorepo?

It shares build/test results across every engineer and every CI run, not just within one machine's local cache — the second engineer building unchanged code gets an instant cache hit from the first engineer's (or a prior CI run's) already-computed result.

How does distributed build execution differ from remote caching?

Caching reuses previously computed results; distributed execution actually spreads the work of building uncached targets across multiple machines in parallel — a genuinely different, complementary lever for when cache misses are still too slow serially.

Why do merge queues matter more at monorepo scale?

High merge-request volume against one shared trunk creates a much higher chance two merges individually pass CI but conflict when combined — a merge queue tests each candidate against the true, most-current trunk state before actually merging, avoiding a broken main.

Name two Git scaling techniques this chapter covers for very large monorepos.

Sparse checkout / partial clone (only fetching the subset of the repo a given job actually needs) and shallow clone (limiting history depth) — both reduce the sheer I/O cost of checking out a repository that has grown very large.

How does independent deploy scope differ from build scope in a monorepo?

A monorepo can build/test many services together while still deploying each one independently and on its own cadence — build scope (what CI verifies together) and deploy scope (what actually ships together) are deliberately decoupled, not the same boundary.

What monorepo-specific security consideration does this chapter flag?

Path-scoped ownership and access control matter more, since a single repository now spans many teams' code — without careful CODEOWNERS-style scoping, one team's compromised credentials or careless merge can reach code far outside their actual area of ownership.


Part 13 Questions: Progressive Delivery with Argo Rollouts & Flagger#

What's the core architectural difference between Argo Rollouts and Flagger?

Argo Rollouts introduces its own Rollout CRD that replaces a standard Kubernetes Deployment outright; Flagger's Canary CRD instead wraps an existing Deployment, leaving it in place and managing traffic shifting around it.

What does the Rollout CRD replace, and why does that matter operationally?

It replaces the standard Kubernetes Deployment object — meaning existing manifests must be migrated to Rollout, a real, one-time adoption cost Flagger's wrapping approach avoids by design.

What does an AnalysisTemplate do in Argo Rollouts?

Defines the metric queries (against Prometheus, Datadog, or another provider) and pass/fail thresholds used to automatically judge whether a canary step should proceed, pause, or trigger an automated rollback — turning progressive delivery from a manual, human-watched process into a genuinely automated one.

How does SLO-gated rollout tie progressive delivery to error budgets?

The same error-budget concept from this course's SRE Fundamentals series becomes the actual gating metric an AnalysisTemplate checks — a canary step only proceeds if it isn't burning error budget faster than the SLO allows, connecting rollout automation directly to reliability targets rather than an arbitrary fixed threshold.

What's the Experiment CRD for?

Running a comparison between two versions without ever promoting either one to be the primary — useful for A/B-style measurement or side-by-side evaluation that's explicitly not meant to end in a full rollout.

Distinguish canary from blue-green in Argo Rollouts.

Canary gradually shifts a growing percentage of traffic to the new version via setWeight steps, analyzed at each step; blue-green keeps both versions fully deployed and switches all traffic at once via a router/Service change — the same tradeoff (blast-radius control vs. instant full-traffic rollback) already established generally in Part 1.

What's the difference between fixed thresholds and Kayenta-style statistical analysis for judging a canary?

A fixed threshold checks a metric against one static number; Kayenta-style statistical analysis compares the canary's full metric distribution against the baseline's, catching regressions a single static threshold could miss or false-positive on due to normal noise.

Why are database migrations a genuine complication for progressive delivery?

A canary and the stable version run simultaneously against the same database — a migration must remain compatible with both the old and new application code during that overlap window, which is exactly the expand/contract migration pattern this chapter (and Part 3's GitOps chapter) requires.

How does Flagger's webhook system work?

Flagger calls out to configurable webhooks at defined points in a canary's lifecycle (pre-rollout, rollout, post-rollout, confirm-promotion) — letting a team hook in custom checks (load testing, manual approval gates) without Flagger needing to natively understand every possible verification step.

What's an ephemeral preview environment per pull request, and which tool in this chapter enables it?

A short-lived, fully deployed environment spun up automatically for a single PR/branch and torn down when it closes — covered as one of Argo Rollouts' progressive-delivery-adjacent capabilities, letting reviewers test a real running version of a change before merge.


Part 14 Questions: Self-Hosted Runner Scaling & Cost Optimization#

Name the two layers of the "two-layer autoscaling problem" this chapter introduces.

Pod-level autoscaling (the CI platform's own controller — ARC, GitLab's Kubernetes executor — scaling runner Pods against job queue depth) and node-level autoscaling (Cluster Autoscaler or Karpenter, scaling the underlying compute those Pods actually schedule onto) — Pod-level autoscaling alone accomplishes nothing without node capacity to match.

Why does minRunners: 0 matter?

It's the concrete YAML expression of true scale-to-zero — zero standing runner Pods (and therefore zero standing compute cost) exist when no jobs are queued, the property that makes ephemeral, Kubernetes-based runners fundamentally cheaper than a static VM pool sized for peak.

Why are CI workloads unusually good matches for spot/preemptible pricing?

The two properties that make a workload risky on spot — long-running and stateful — are exactly what CI jobs are not: they're short-lived and (with correctly externalized caching) effectively stateless, making an interruption cheap to simply retry rather than dangerous.

What's the "crossover point" concept this chapter builds its economic argument around?

The usage volume (illustratively, ~50,000 monthly build-minutes) above which self-hosted infrastructure cost — including real, honestly counted operational burden, not just raw compute pricing — becomes cheaper than staying on hosted-runner minutes.

Why do ephemeral, single-job runners solve both a security problem and a cost problem with the same architectural choice?

No state persists between jobs, closing the same "a compromised job can't infect the next one" risk covered in the platform-specific security chapters, while simultaneously having zero idle time between jobs — the same design decision resolves both concerns at once rather than trading one against the other.

What concrete GitHub pricing change does this chapter flag as current for 2026?

GitHub introduced a $0.002/minute platform fee on self-hosted runner minutes for private repositories, effective March 2026 — self-hosted runners no longer cost GitHub literally $0, though they remain meaningfully cheaper than hosted-runner rates.

What's the key difference between Cluster Autoscaler and Karpenter?

Cluster Autoscaler scales pre-defined, fixed-shape node groups up and down; Karpenter provisions individual nodes matching a Pod's actual resource requirements directly, with no pre-defined node group needed — giving it materially better bin-packing and node-shape flexibility for bursty, heterogeneous CI workloads.

Why is CircleCI's self-hosted runner architecture the outlier in this chapter's platform comparison?

It's built around a long-running agent process polling for jobs, not the Kubernetes-native, ephemeral-Pod-per-job model that GitHub's ARC, GitLab's Kubernetes executor, and Jenkins' Kubernetes plugin all converge on — a genuine architectural difference, not a maturity gap.

What compliance implication does self-hosting runner infrastructure introduce?

It expands an organization's own audit scope to genuinely include the runner infrastructure itself (node patching cadence, CVE response, physical/cloud security posture) — work previously carried entirely by the hosted platform vendor and outside the org's own compliance boundary.

Per this chapter, when should a team NOT self-host even after clearing the volume crossover point?

When genuine, staffed Kubernetes operational capacity isn't actually available — adopting this chapter's full stack without real ongoing expertise to maintain it produces a fragile fleet that costs more in firefighting than it saves in infrastructure spend.


Quick-Fire / Rapid Recall#

QA
CI in one line?Merge small changes frequently, build/test automatically on every merge
Delivery vs Deployment?Human decides when vs. fully automatic, no gate
Fastest rollback deployment strategy?Blue-green (instant router switch)
Strategy that limits blast radius most?Canary
Feature flags decouple what from what?Deploying code from releasing a feature
DORA's Four Keys?Deployment Frequency, Lead Time, Change Failure Rate, Time to Restore
DORA's key finding about speed vs stability?They reinforce each other, not a tradeoff
Provisioning vs configuration management tools?Terraform vs. Ansible
Most important IaC property?Idempotency
Command that shows changes before they happen?terraform plan
Why remote state + locking?Shared, durable, prevents concurrent-apply corruption
What causes drift?Manual changes bypassing the IaC tool (e.g. console edits)
Is Ansible agent-based?No — agentless, over SSH
GitOps's 4 principles?Declarative, versioned/immutable, pulled automatically, continuously reconciled
Push vs pull deployment — which is GitOps?Pull
Why is pull more secure?No external system needs standing production credentials
Two dominant GitOps tools?ArgoCD and Flux
ArgoCD setting for auto-drift-correction?selfHeal: true
How are secrets handled in GitOps?Sealed Secrets (encrypted) or External Secrets Operator (reference only)
GitOps rollback mechanism?git revert
Why does GitOps help disaster recovery?Git IS the complete desired state — point a new agent at it to rebuild everything
GitHub reusable steps vs. reusable jobs?Composite Action vs. Reusable Workflow
Why SHA-pin a GitHub Action?Tags are mutable; a SHA is immutable — prevents a hijacked-tag supply-chain attack
What does permissions: id-token: write enable?Requesting an OIDC token for cloud auth — without it, no token is available
GitHub's manual-approval mechanism?Environment required reviewers
The pull_request_target trap in one line?Elevated write token + executing the PR's own untrusted head code, combined
GitLab's default job scheduling model?Stage-sequential — needs: builds a DAG that breaks free of it
GitLab's modern reusability primitive?CI/CD Components (versioned evolution of include:)
What guarantees main is always tested against its true future state at high MR volume?Merge trains
GitLab's near-one-line built-in security scan?include: template: Security/SAST.gitlab-ci.yml (and DAST/dependency/secret equivalents)
Bitbucket's standout, hard-to-replicate strength?Native Jira integration (Smart Commits, deployment tracking)
Bitbucket's biggest reusability gap vs. GitHub/GitLab?No native matrix-build primitive
Bitbucket's OIDC opt-in?oidc: true on the step
Only platform in this series that builds/deploys from ANY git host?Azure DevOps
Azure's non-bypassable reuse mechanism?extends: (vs. plain template:, which is opt-in)
Strongest org-wide governance mechanism covered in this series?Azure pipeline decorators — zero reference required from any pipeline
Azure's native first-class deployment strategies?runOnce, rolling, canary
Jenkins's controller vs. agent?Controller schedules/serves UI; agents execute steps
Jenkins's reusability mechanism?Shared Libraries
Jenkins's controller-level config-as-code?JCasC
CircleCI's billing unit?Compute credits, not flat per-minute
CircleCI's reusability mechanism?Orbs
CircleCI's standout large-test-suite feature?Timing-based parallel test splitting
Tekton's fundamental nature vs. every other platform here?Composable primitives (CRDs), not a finished platform
Tekton's automatic attestation component?Tekton Chains
Why does every Tekton Step run in its own container?Strong isolation — no shared shell state between steps
Monorepo CI's core problem?Avoiding "build/test everything" on every push at scale
The 3 monorepo build-graph tools compared?Nx, Turborepo, Bazel
Bazel's standout property?Fully hermetic, reproducible builds
Monorepo's real caching force multiplier?Remote caching shared across every engineer/CI run
Argo Rollouts vs. Flagger — core difference?Rollout CRD replaces Deployment vs. Canary CRD wraps it
What gates an automated canary's progression?AnalysisTemplate metric checks (optionally SLO/error-budget-driven)
Progressive delivery's DB migration requirement?Expand/contract compatibility during the canary overlap window
The two-layer autoscaling problem's two layers?Pod-level (platform controller) and node-level (Karpenter/Cluster Autoscaler)
Why are CI jobs a good spot-instance fit?Short-lived and stateless — the two properties that make interruption safe
What architecturally sets CircleCI's self-hosted runner apart?Long-running polling agent, not Kubernetes-native ephemeral Pods
GitHub's 2026 self-hosted runner cost change?$0.002/min platform fee on private-repo runner minutes