# Gathering the facts Every value in `docs/agents/delivery.md` has exactly one source. Facts the repo holds come from the repo; facts only a human holds come from the human. A value with no source stays out. ## Repo-sourced ### Contents → skills 1. List the repo's top-level layout and the tool each area belongs to: Flux/Kustomize manifests (`kustomization.yaml`, `HelmRelease`), Kubernetes manifests, Ansible (`playbooks/`, `roles/`, `inventory/`, `ansible.cfg`), OpenTofu (`*.tf`, `.terraform.lock.hcl`). 2. The installed skills are the session's available-skills listing. Map a glob only to tool skills in that listing whose description covers the area's tool. 3. In a mixed repo (for example Ansible at the top level, Flux under `clusters/`), map each area with its own glob, and leave out any area with no installed tool skill. ### CI checks 1. Read every workflow under `.gitea/workflows/` or `.github/workflows/` that runs on `pull_request` or `pull_request_target`. A path-filtered `pull_request` workflow still counts: Gitea reports it as "skipped" when its paths don't match. List it, usually with role `test`. Workflows that run only on push, schedule or dispatch are not PR checks; leave them out. 2. Derive each candidate name: - Gitea Actions: ` / ()`. The workflow name is the file's top-level `name:` (else the file name); the job name is the job's `name:` (else the job id). - GitHub Actions: the job's `name:` (else the job id); matrix jobs append their values in parentheses. 3. Confirm each candidate against the statuses the forge reports on the head commit of a recent PR where that check reported at least once. Gitea: `gitea-prs` → `pull_request_read` method `get_status`, or `commit_read` status on the head SHA; GitHub: `gh pr checks `. The forge's string wins over the derived one. With no PR to read, keep the derived name and say so in the PR body. 4. Assign roles. `test-path` is the check that fails when a commit after the `Delivery-Stage: test-author` commit touches the test globs. `dry-run` and `dry-run-gated` come from the human: a dry run whose workflow waits for a label (a `labeled` trigger or a label condition on the job) is a `dry-run-gated` candidate to confirm, never assigned unasked. A gated check's name must come from the forge, read on a PR where the gated job ran (step 3). With no such PR, list it as open in the PR body instead: a wrong name stays `awaiting-gate` forever and never blocks. ### Test paths 1. Read the test-path check's workflow and find the file it reads its globs from (for example `.gitea/test-paths`). If one exists, the section is the `globs file:` pointer. 2. Otherwise list the globs where the repo's tests live (Molecule scenarios, `tests/`, policy tests). Confirm them with the human in the Step 3 question. ### Post-merge checks 1. Read every workflow that runs on `push` to the default branch. Derive each status name as for CI checks, with the `(push)` suffix, and take its `paths:` filter as the item's globs. A workflow with no path filter gets one item per top-level directory it reads or applies, confirmed with the human in the Step 3 question. Confirm each name against the statuses on a recent default-branch merge commit (`commit_read` status on its SHA; GitHub: `gh api repos///commits//check-runs`). With none to read, keep the derived name and say so in the PR body. 2. Each area Flux pulls (the paths a `Kustomization` reconciles from this repo) gets `` - ``: none ``. 3. Write one glob per line and no brace globs. An area with neither a push workflow nor a pull is left out: nothing checks it after merge. 4. List only cumulative workflows (format.md §7): one that applies just its own commit's diff is left out. So is a push workflow whose status names change with routine updates, such as matrix keys embedding image digests: an exact name would go stale. Name each workflow left out, and why, in the PR body. ### Conventions Point at the root `AGENTS.md`, `docs/adr/`, and any contributing or runbook docs that exist. A list of pointers the human or caller supplies replaces these defaults. ## Human-sourced SKILL.md Step 3 asks for these: - Human allowlist: forge usernames. - Bot user the agents act as. - Read-only kubeconfig path, or "no cluster". - Branch-protection status: in place, or pending with the tracking link. - Which CI checks are dry runs, and which of those are label-gated: they post a status only after an allowlisted human adds a label. For each gated one, confirm its workflow runs only on that one named label (the filter read from the workflow). A repo with PR checks but no ungated dry-run check is not ready for the delivery team: say so in the PR body as open and stop. - Test-path globs, when no globs file exists (confirm the derived list). - Post-merge items for a push workflow with no path filter (confirm the derived directories). - Accepted risks: the ADR or issue links, or "none".