Watch
0
0
Fork
You've already forked hyperhive
0
Commit graph hyperhive/swarm-controller
Author SHA1 Message Date
iris
da5fcbfd9b subagents publish their model and effort as headers on every row, and the swarm shows them
The subagent daemon stamps Swarm-Model and Swarm-Effort on each row it
publishes. The list endpoint reads them off the newest row it already fetches,
so a long-running subagent keeps them past the stream's 24 hour window, and the
terminal page's menu and the agent panel's list show them beside the name.
2026-10-28 21:55:02 +01:00
atlas
22522b386a log the proxy-credential, cache-miss and users-file passes at info, with counts in the message 2026-10-28 19:57:53 +01:00
atlas
cbe41bea54 rebuild an agent's closure when the binary cache lost it 2026-10-28 13:51:01 +01:00
atlas
ec06a91deb mint per-agent proxy credentials and a per-hive squid self-check credential 2026-10-28 13:50:35 +01:00
atlas
b1a00a3222 request the review classifier when a pr is opened or reopened 2026-10-28 10:22:13 +01:00
atlas
57b04d6c49 let the operator set, replace and remove an agent's backend env from the swarm ui 2026-10-28 08:49:32 +01:00
atlas
1e5070796d copy the cache's pull facts to each hive and create them in the in-swarm cache
the in-swarm cache stores its address, name and public key beside its tokens, create-only. swarm-controller copies the four cache facts to swarm/hives/<hive>/attic/* every five minutes, with read on the sources and write on the copies. part 1 of 3: nothing reads the copies until the hive reader and probe land.
2026-10-28 01:19:56 +01:00
atlas
d5c5862654 keep the matrix appservice registration in bao, with the host file as the last copy 2026-10-27 17:33:06 +01:00
atlas
ae8b2d39ec swarm: merge a re-create into the stored agent permissions instead of overwriting them 2026-10-27 14:44:41 +01:00
atlas
8699857024 swarm: unrestricted_internet flag on the agent permissions record, unset reads as on, create writes false 2026-10-27 14:44:41 +01:00
atlas
0849afec80 push green meta builds to the attic cache and record cached 2026-10-27 13:02:43 +01:00
atlas
a4e48a7bca store the forge webhook secret and grafana's secret key in bao, seeded from the existing files 2026-10-27 13:00:13 +01:00
atlas
09d89507a9 name the agent's entity before narrowing its role, and test hive provisioning against a fake store 2026-10-27 10:11:02 +01:00
atlas
139007e656 stop writing and attaching per-agent and per-hive bao policies 2026-10-27 10:11:02 +01:00
atlas
701efadfe4 only the controller's own comments carry the marker, and a cleared comment says resolved 2026-10-26 23:16:53 +01:00
atlas
9fc0e3bf90 comment once per pr and agent while red, clear the marker on a green build 2026-10-26 23:16:53 +01:00
atlas
0bc5a7e475 comment once on a merged config pr when its swarm build fails 2026-10-26 23:16:53 +01:00
iris
a2f000bab4 swarm-ui: builds are a card under the job graph on the jobs tab
The builds tab is gone from the nav; its card sits below the jobs card on
/jobs. The swarm-builder commit status now links to /jobs?run=<id>, and the old
/builds address redirects there with its query so links already on PRs still
open the build. Docs and the link test follow.
2026-10-26 20:02:57 +01:00
atlas
59456c3c58 retry every failed meta build each round, a timeout included, and drop the attempt count 2026-10-26 18:52:33 +01:00
atlas
99d2ed5b9e build a failed meta build once more, and treat a timeout or missing grant as no verdict 2026-10-26 18:52:33 +01:00
atlas
5e64048e53 gate each deploy on a swarm build of the agent from internal/meta 2026-10-26 18:52:33 +01:00
iris
d273fa8028 docs: fold swarm/secrets.md into the credentials reference
secrets.md and credentials-reference.md answered the same question from two
pages. secrets.md's text now follows the reference's table and operating
notes as a 'Where each secret lives' section, unchanged apart from where it
sits. Every link and doc path that named secrets.md (docs, nix comments,
crate READMEs) points at credentials-reference.md; anchors are unchanged.
2026-10-26 18:10:01 +01:00
iris
0b03ed6c35 swarm-controller: point the matrix_account doc at the page that now holds the main-account note 2026-10-26 18:10:01 +01:00
atlas
03796f1964 add one shared templated hive policy keyed on the cert alias name 2026-10-26 11:36:55 +01:00
atlas
4cdf807afc add one shared templated agent policy and name each agent's bao entity after it 2026-10-25 21:50:06 +01:00
atlas
35dcc52e21 add no-binary-blobs to the classifier rules-file test 2026-10-25 20:27:07 +01:00
atlas
e592078868 move client-cert gauges behind an otel feature of swarm-secret-client, drop the crate 2026-10-25 19:02:49 +01:00
atlas
078696aaee export bao client-cert not_before/not_after gauges and alert past 80% of lifetime 2026-10-25 19:02:49 +01:00
atlas
cce00a6592 swarm-builder: log each archetype eval's elapsed time, wait 5 minutes 2026-10-25 18:42:44 +01:00
atlas
dd2f0d3ece let notification flows start from submitted pull request reviews 2026-10-25 16:56:12 +01:00
atlas
716290e4d2 swarm-controller: state route refuses an agent the swarm has not declared on that hive
A placing state is accepted only for an agent declared or queued on the hive; anything else gets 404 telling the caller to create it at swarm level. swarm-ui's wanted badge no longer offers a first declaration for an undeclared row.
2026-10-25 15:58:25 +01:00
atlas
633139069f redeclare the deploys a failed meta update skipped on the timer's retry
queue_meta_update adds a TriggerDeploy behind each retry UpdateMeta (after_ok) for every agent whose latest deploy waited on a failed update. A created or merged agent whose deploy was skipped is deployed by the run that succeeds; a deploy skipped for another reason, or an agent already deployed, gets nothing.
2026-10-25 15:32:16 +01:00
atlas
61e35ab603 deploy only after a successful meta update
A hive builds only from internal/meta, so a TriggerDeploy after a failed UpdateMeta could only fail its build. Both DAGs that queue an update (merged config PR, agent create) now gate the deploy with after_ok: the update shows Failed and the deploy Skipped.
2026-10-25 15:32:16 +01:00
atlas
4aa11b3a94 build agents only from internal/meta; delete the hive's local meta flake
The hive no longer renders, locks or commits a meta flake. A rebuild's
MetaSync node picks the internal/meta commit and records it with the
hyperhive and config pins it holds; Prebuild, Swap and Create build from it,
and a head that does not pin the agent's current config fails the build
naming the agent. hive-priv's meta_rev is required.

Removed: meta.rs sync/lock/render, the manual-rebuild relock, the boot
sweep's hyperhive bump (MetaLock), the update-meta-inputs form and its
panel, MetaWindow, the hive's hyperhive_rev setting.

Kept: agent_set::refresh holds what sync_agents also did (topology.json, the
gateway's agent-socket map and nginx include), called from spawn, destroy,
rebuild and the migration.

The boot reconcile and the stale-start upgrade compare the agent's marker
with the hyperhive pin of internal/meta; the dashboard's deployed chip reads
the config marker a successful build writes.
2026-10-25 15:32:16 +01:00
atlas
31cb6bfa42 queue the meta update only until one run succeeds 2026-10-25 12:56:48 +01:00
atlas
0f1ba6e630 log failed controller jobs, re-run the meta update every ten minutes 2026-10-25 12:25:01 +01:00
atlas
3d142feb6a log refused agent-permission changes on the controller api 2026-10-25 11:33:12 +01:00
atlas
8b255b43a0 docs: describe the recorded meta fan-out pin 2026-10-25 11:06:53 +01:00
atlas
2b9927fda2 fan out the meta pin by a recorded pin, not by the move 2026-10-25 11:06:53 +01:00
atlas
e8538d8690 swarm-controller: POST /api/notify/dry-run runs a draft flows document 2026-10-25 11:00:38 +01:00
atlas
4d9b7e0ca9 agent store leaf: 7 days instead of 90 2026-10-25 10:23:35 +01:00
atlas
eaf26aaadd review classifier: export request, verdict, check and run metrics, with a dashboard
The controller counts review requests, verdicts and per-check results and times each run; the classifier service counts retried asks. A provisioned Grafana dashboard charts them.
2026-10-24 23:24:31 +02:00
atlas
ed1fd053e7 notify router: deliveries log, dry-run hit counts, api and page 2026-10-24 22:13:07 +02:00
atlas
bbc6174361 leave an agent with no config commit out of internal/meta; read config heads from main
on deploy, one agent whose agent-configs repo has no commit on main is
skipped and logged instead of failing the whole internal/meta render, so the
other agents' pin moves go through. the controller reads each config head
from main, the branch hive-c0re compares against, not the repo's default
branch.
2026-10-24 21:13:25 +02:00
atlas
22e2d30581 pin internal/meta's hyperhive on the controller's rev and rebuild agents when it moves
The swarm controller offers its own running rev (services.hyperhive.c0re.
hyperhiveRev) as the hyperhive pin of internal/meta and takes it only when
the forge compare API shows it descends from the committed pin; merges to
hyperhive main no longer move the pin, and the first commit pins main's head.
When a commit moves the pin, every placed agent gets a TriggerDeploy.

A deploy after a meta update no longer waits on it succeeding (after_any), so
a down builder does not hold back hives that render locally.
2026-10-24 21:13:24 +02:00
atlas
5950363a10 swarm-controller: render, lock and commit internal/meta
A new update_meta node renders internal/meta's flake.nix with
hive-meta-flake, the renderer hive-c0re uses: hyperhive pinned to its
forge main, each custom agent a hive places pinned to its agent-configs
main, all over https, and the swarm-wide values from
SWARM_CONTROLLER_META_FLAKE (set by swarm-controller.nix from
services.hyperhive.swarm.*). The swarm builder locks it, and the
controller commits flake.nix and flake.lock in one commit and gives
every hive's forge account read on the repo. A render equal to the
committed flake.nix sends no lock and commits nothing.

It runs at start, when hyperhive's main moves, before the deploy of a
merged config PR and before the first deploy of a new agent; those
deploys now wait for it. agent_web_port moves into hive-meta-flake so
both callers compute the same port; hive-c0re re-exports it.

On deploy: internal/meta appears on the forge and follows every merge.
No hive builds from it yet.

Refs #4857
2026-10-24 21:13:24 +02:00
atlas
26c4ff89d5 approve a requested review when the repo has no review rules
On deploy: a review requested of the review classifier on a PR whose repo
holds neither .hyperhive/review-classifier.yml nor .json on its default
branch now posts an APPROVED review at once, saying no review rules are
configured for the repo and it was approved without checks. No model call
is made. Before, that case posted a "No verdict" comment. A rules file that
exists but fails to load or parse still posts no verdict. The rule model is
unchanged and instance-wide: every repo without a rules file is approved.
2026-10-24 17:28:40 +02:00
atlas
0b1669a364 request the review classifier's review when a PR's head moves
The router gets a request_reviewer node and a pull_request_sync source;
the built-in head-classifier flow asks swarm-controller, over
$SWARM.router.sink.request-reviewer, to request review-classifier on
every push, unless its review of the head already stands. The controller
subscribes to pull_request_sync on its pull-request hook and answers
the router; nats-auth grants the router the publish and the controller
the subscribe.
2026-10-24 17:23:36 +02:00
atlas
d5802d16a0 notify flows: GET returns a schema of the events, fields, node kinds and limits 2026-10-24 13:35:39 +02:00
atlas
ada364a482 notify flows: refuse unknown placeholders and require the revision read on every save 2026-10-24 12:12:27 +02:00