Borrowing it
Nothing to install: this file belongs to fold-run/fold. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/fold-run/fold/main/.claude/skills/discovery-controller/SKILL.mdgit clone --depth 1 https://github.com/fold-run/foldWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/fold-run/fold/discovery-controller)<a href="https://agentmods.dev/skills/fold-run/fold/discovery-controller"><img src="https://agentmods.dev/badge/skills/fold-run/fold/discovery-controller/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/fold-run/fold/discovery-controller"><img src="https://agentmods.dev/badge/skills/fold-run/fold/discovery-controller.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00066 | $0.01286 |
| Opus 5.5 | $0.00026 | $0.00514 |
| Sonnet 5.5 | $0.00013 | $0.00257 |
| Haiku 4.5 | $0.00007 | $0.00129 |
Grade A, and why
discovery-controller scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 107 lines — stays where its author put it; the contents beside it link to each section on GitHub.
The Kubernetes discovery controller
fold-discovery lists Services matching a label selector on an interval,
maps them to upstream entries via annotations, validates them with fold's
own config package, and serves {"upstreams": [...]} for the gateway's
discovery.url to poll.
Linux-only (goreleaser builds it for linux alone) — it runs in a cluster, listing Services with the pod's service account.
The constraint that shapes the whole package
Poll-to-poll, no client-go, no informers. fold polls the producer; the producer polls the Kubernetes list API with the pod's service-account token and plain HTTP. That is the entire Kubernetes client.
This keeps fold's module free of the Kubernetes dependency tree, and it is
load-bearing rather than incidental: go.mod has 14 direct dependencies
and pulling in client-go would multiply that, in a binary operators run at
the edge of their network. Do not add client-go, informers, or a
controller-runtime dependency to make something more elegant. If a change
seems to need watch semantics, it needs a shorter interval.
The trust boundary is the reason for every allowlist flag
A Service annotation is a lower-trust input than the config document. Anyone who can create a Service in a watched namespace can propose an upstream. Every flag below exists to bound what that person can propose, and each defaults to the safe end:
| Flag | Default | What it stops |
|---|---|---|
--allow-auth-strategies |
none | A Service choosing how the gateway authenticates to it |
--allow-secret-refs |
none | A Service naming an env var whose value it wants sent |
--allow-credential-hosts |
unrestricted | A credentialed Service pointing at an attacker's host |
--reserved-ids |
empty | A Service claiming the id or namespace of a static upstream |
--allow-unprefixed-ids |
off (prefixing on) | Cross-namespace id collisions; single-tenant clusters only |
--min-health-interval-ms |
1000 | A Service asking for a probe loop that hammers itself |
--bearer-env |
none | An unauthenticated reader of the discovery document |
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2mo ago First seen · 107 lines · 66 tokens per session scan A 3daec6be2b31
discovery-controller is a skill published in the GitHub repository fold-run/fold (1 stars, last pushed 12d ago), licensed Apache-2.0. It adds 66 tokens to every session and 1,286 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
discovery-controller compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| discovery-controllerfold-run/fold | Skill | 1 | 12d ago | Apache-2.0 | A | 66 | Claude Code |
| bmad-shard-docmmornati/leanproxy-mcp | Skill | 5 | 1mo ago | MIT | A | 34 | Claude Code, Codex |
| bmad-document-projectmmornati/leanproxy-mcp | Skill | 5 | 1mo ago | MIT | A | 29 | Claude Code, Codex |
| migrate-goldmark-extension-v1-to-v2yuin/goldmark | Skill | 5.1k | 4d ago | MIT | A | 26 | Claude Code |
| octo-driveMininglamp-OSS/octo-cli | Skill | 922 | yesterday | Apache-2.0 | A | 55 | Claude Code, Codex |
| pi-loop-forensicsdimetron/pi-go | Skill | 222 | 3d ago | MIT | A | 65 | Claude Code, Codex |
| nightly-session-watchdimetron/pi-go | Skill | 222 | 3d ago | MIT | A | 78 | Claude Code, Codex |