/cub-scout:operator-incident-evidencefrom cub-scout
Assembles a structured, immutable evidence package for postmortems using cub-scout trace, compare, bundle, history, audit, and receipt commands. Read-only by design.
Ships in cub-scout. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
The postmortem-evidence loop. After the incident is past peak (or fully resolved), the operator needs to assemble a structured evidence package for the postmortem doc, the release-engineering meeting, or the audit ticket. This skill composes trace + compare three-way + bundle + history + audit + receipt verify --save into a deterministic, fingerprinted record.
Read-only by design. Postmortems should never mutate cluster state — capture, don't fix.
Explicit phrasings:
Implicit intents:
triage-unhealthy-workloadinvestigate-driftmigrate-from-kubectltrace + explain + compare three-way for each affected resource, with --format json so the output is machine-parseable.bundle produces a debug-bundle archive that captures the cluster state at this moment for offline replay. snapshot produces a GSF JSON snapshot.history for the ConfigHub ChangeSet timeline; audit list for ConfigHub audit entries; impact for blast-radius.receipt verify --save for each affected resource, with the relevant predicate (applied-matches-spec, source-truth-pass, no-manual-edits-since). Receipts are immutable; they freeze the verdict at this moment.receipt validate <path> confirms the artifact wasn't tampered with between capture and review.For the worked example: payments-api deployment broke between 14:00 and 16:00 UTC on 2026-05-22, recovered via Argo rollback at 16:15. Operator wants to capture evidence at 17:00 for the postmortem.
$ INCIDENT_START="2026-05-22T14:00:00Z"
$ INCIDENT_END="2026-05-22T16:15:00Z"
$ RESOURCES=("deploy/api" "deploy/worker") # affected workloads
$ NAMESPACE="prod"
$ OUT_DIR="./incident-2026-05-22-payments"
$ mkdir -p $OUT_DIR
# Per-resource explain + trace + three-way as JSON
$ for r in "${RESOURCES[@]}"; do
safe=$(echo "$r" | tr / -)
cub-scout explain "$r" -n $NAMESPACE --format json > "$OUT_DIR/${safe}-explain.json"
cub-scout trace "$r" -n $NAMESPACE --format json > "$OUT_DIR/${safe}-trace.json"
cub-scout compare three-way "$r" -n $NAMESPACE --format json > "$OUT_DIR/${safe}-compare.json"
done
Each file is a structured contract — explain has the ownership + cause + nextSteps; trace has the ownership chain + git revision + secrets; compare three-way has the per-field DRY/WET/LIVE plus per-field attribution.
# Bundle archive (offline-replayable)
$ cub-scout bundle summarize -n $NAMESPACE -o "$OUT_DIR/cluster.bundle.tar"
# Or GSF JSON snapshot (for diff'ing later)
$ cub-scout snapshot -n $NAMESPACE --format gsf > "$OUT_DIR/cluster-snapshot.gsf.json"
bundle archives are the canonical "this is what cub-scout saw" artifact. Replay with cub-scout bundle inspect/replay/diff against a different bundle (e.g., the pre-incident bundle from this morning's automated capture) to see what actually changed.
If cub-scout status --json reports confighub_reads: true (the ConfigHub session check passes; cub auth status checks the same session):
# ChangeSet timeline for each unit
$ for r in "${RESOURCES[@]}"; do
safe=$(echo "$r" | tr / -)
cub-scout history "$r" -n $NAMESPACE --format json > "$OUT_DIR/${safe}-history.json"
done
# Audit trail (read-only access to ConfigHub audit log)
$ cub-scout audit list --since $INCIDENT_START --until $INCIDENT_END --format json > "$OUT_DIR/audit-log.json"
# Blast-radius for the primary affected unit
$ cub-scout impact payments-api --format json > "$OUT_DIR/impact.json"
history is particularly valuable: ChangeSets show who applied what and when. If a ConfigHub apply at 13:55 (just before the incident) is the trigger, history makes it obvious.
# applied-matches-spec — what was the controller saying right after recovery?
$ for r in "${RESOURCES[@]}"; do
cub-scout receipt verify "$r" -n $NAMESPACE --predicate applied-matches-spec --save --save-dir "$OUT_DIR/receipts"
done
# no-manual-edits-since the rollback completed — proves no human touched the resources during recovery
$ for r in "${RESOURCES[@]}"; do
cub-scout receipt verify "$r" -n $NAMESPACE --predicate no-manual-edits-since --since "$INCIDENT_END" --save --save-dir "$OUT_DIR/receipts"
done
# source-truth-pass if you want the strategy-typed verdict on whichever delivery chain was active
$ for r in "${RESOURCES[@]}"; do
cub-scout receipt verify "$r" -n $NAMESPACE --strategy git-argo --save --save-dir "$OUT_DIR/receipts"
done
Each receipt is a fingerprinted, immutable JSON artifact. SHA-256 over RFC 8785 canonical JSON of the full in-toto Statement v1 envelope. If someone questions the evidence later ("are you sure that's what the cluster looked like?"), receipt validate <path> confirms it.
See scout-verify for the receipt surface in detail.
$ ls "$OUT_DIR"
audit-log.json
cluster.bundle.tar
cluster-snapshot.gsf.json
deploy-api-compare.json
deploy-api-explain.json
deploy-api-history.json
deploy-api-trace.json
deploy-worker-compare.json
deploy-worker-explain.json
deploy-worker-history.json
deploy-worker-trace.json
impact.json
receipts/2026-05-22T17-00-00Z__applied-matches-spec__Deployment-api__abc123.receipt.json
receipts/2026-05-22T17-00-00Z__no-manual-edits-since__Deployment-api__def456.receipt.json
...
$ tar czf "incident-2026-05-22-payments.tar.gz" "$OUT_DIR"
$ # ship to S3 / a git LFS path / the SEV ticket
The archive is now the postmortem source-of-truth. Anyone reviewing the incident can extract it and run cub-scout receipt validate / bundle inspect against the artifacts to confirm authenticity.
triage-unhealthy-workload is the 30-second loop during the incident. Pager firing, time-pressed, evidence is incidental.operator-incident-evidence is the postmortem loop after the incident. Time has eased; the goal is complete, structured, immutable capture. Different audience, different output shape.Use both: triage first (during), evidence-capture second (after).
$ cub-scout receipt list --dir ./incident-2026-05-22-payments/receipts --format json | jq '.[] | {predicate: .predicateName, verdict: .verdict, scope: .scope.name}'
$ for r in ./incident-2026-05-22-payments/receipts/*.receipt.json; do
cub-scout receipt validate "$r" || echo "TAMPERED: $r"
done
receipt validate exits 0 if the fingerprint matches; 1 if tampered; 2 on I/O error. The exit-code shape makes it CI-friendly — wire into the postmortem-package-publish workflow.
scout-verify — receipt verbsscout-govern — bundle / history / audit / impacttriage-unhealthy-workload — the during-incident counterpartinvestigate-drift — for the per-resource attribution dimensiondocs/howto/bundle-diff.md, docs/howto/bundle-timeline.mddocs/reference/json-contracts.md § Receipt Contract#328, #360incident-<date> directory to off-cluster storage (S3, git LFS) the moment capture completes. The local store is $XDG_DATA_HOME/cub-scout/receipts by default but a local disk can be lost.--save-dir to land in the incident folder rather than the operator's default local store. Keeps the incident package self-contained.audit list or history are unavailable (standalone mode, ConfigHub auth lapsed), record that explicitly in the postmortem — missing connected-mode evidence is a known gap, not silent absence. The omissions[] field on the receipt covers the receipt side; the postmortem should call out the bundle/audit gaps independently.What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
Generated from the plugin's indexed repository (confighub/cub-scout) — no native marketplace selected
npx claudepluginhub p/confighub-cub-scout35 skills in this plugin
/ai-agent-readonly-contextUse when the user is WIRING CUB-SCOUT INTO AN AI AGENT (Claude / Codex / a custom LLM workflow) and needs the patterns for read-only context, MCP gateway tools, deterministic context snapshots, and the prompt-shape that makes cub-scout's output reliable for LLMs. Natural phrasing: "set up cub-scout as a Claude tool", "expose cub-scout to my agent over MCP", "give the LLM a deterministic snapshot of this cluster", "what cub-scout patterns work well for AI agents?", "MCP config for cub-scout in Claude Code", "best practices for wiring cub-scout into Codex / Cursor / Continue", "AI-ready cluster context", "prompt template for cub-scout output". Composes `mcp serve` + `context-pack` + `--presentation ai` + the structured JSON contracts. Do NOT load for: a specific verb invocation (load the corresponding scout-* skill), authoring an MCP server in general (this is about wiring CUB-SCOUT specifically), or any mutating workflow (cub-scout never mutates; the read-only triad is the whole point of this skill)./audit-fleet-conformanceUse when the user wants to verify CONFORMANCE ACROSS A FLEET — multiple namespaces, multiple clusters, or a defined View scope. Natural phrasing: "which clusters are conformant?", "audit fleet conformance against this View", "show me all outliers in prod fleet", "compare every service against its source-truth strategy", "scope-wide three-way check for drift", "fleet-level compliance audit", "which deployments drift across the cluster?". Composes `compare three-way --view` + `compare source-truth` + `fleet outliers` for multi-resource / multi-cluster checks. Requires connected mode for the View + ConfigHub surfaces. Do NOT load for: a single resource (use investigate-drift), a triage (use triage-unhealthy-workload), incident evidence for one event (use operator-incident-evidence), or anything mutating.Other plugins' skills for the same job