Watch
0
0
Fork
You've already forked hyperhive
0
Commit graph hyperhive/swarm-controller
Author SHA1 Message Date
atlas
cd786ef401 document the controller tcp listener and its two leaves 2026-11-20 19:24:20 +01:00
atlas
187ed82de0 gateway reaches the controller over tls with its own client leaf when the tcp listener is on 2026-11-20 19:24:20 +01:00
atlas
17fffaae79 swarm-controller serves tls on tcp to the gateway client identity only, when configured 2026-11-20 19:24:20 +01:00
atlas
934da6f31f agent ssh connections: declare per agent, render into the agent's ssh config 2026-11-20 03:10:41 +01:00
maia
ffbd2f4dea swarm-controller: an opt-in plain /healthz and /readyz listener a kubelet can probe 2026-11-19 12:23:17 +01:00
maia
96cb25a040 swarm-controller: a stop signal ends the startup secret-store reads
The queue client secret and the webhook secret are read at start through
a retry schedule of about a minute. Neither heard SIGTERM, because the
shutdown signal was only installed once the controller began serving, so
a stop during a store outage waited out the schedule or the unit's stop
timeout.

main installs the signal first and passes it to queue_identity::init and
webhook::load. A stop that arrives first ends the read and exits 0.
2026-11-19 10:37:23 +01:00
maia
7df2d646ff swarm-controller: a TokenStore test double covers token mint and rotation
The forge token paths (ensure_*_forge_token, replace_token, observe_agent,
observe_hive) took the concrete SecretStore, so none of them could run
without OpenBao. They now take a TokenStore trait, implemented by
SecretStore, with a FakeTokens double in the store tests.

ensure_hive_forge_token keeps its order: the account and team steps, then
the store login, then the token.
2026-11-19 09:38:13 +01:00
maia
b0239914b8 readiness follows a cached store check instead of a constant or a login per probe 2026-11-19 08:43:43 +01:00
maia
2eacb83b21 a removed hive's OIDC client secret is deleted with its other store credentials 2026-11-19 08:42:46 +01:00
argus
1498ea4290 review classifier: docs describe the current state, not what was removed
A new negative rule: text added under docs/, in a README or a doc comment
that documents something that no longer exists ("nothing reads this file
now", "older versions wrote X"). Migration pages, changelogs and
removed-option messages are exempt. The rules-file test lists the new name.
2026-11-18 20:09:39 +01:00
atlas
c21b158884 swarm daemons: opt-in /healthz and /readyz listener, and /readyz on the controller 2026-11-18 19:06:04 +01:00
atlas
a089da25a5 swarm-logs-auth, swarm-metrics-auth, swarm-authelia-bridge, swarm-controller: drain http on sigterm 2026-11-18 09:45:21 +01:00
atlas
11fec06a50 cut off hives that left the roster: forge token, team seat, token secret, login role 2026-11-17 06:48:05 +01:00
iris
fe4d68c13f the harness no longer publishes the agent's icon; the controller is its only writer 2026-11-17 06:47:48 +01:00
atlas
3032f34269 tests for the ci metrics, builder and hive forge accounts 2026-11-17 00:26:27 +01:00
atlas
c1234973be tests for the forge objects pass: team, rule, repo and mirror writes
adds routed_forge, writes and sent to the forge.rs test module: a stand-in forge
that answers by path. it adds an x-total-count header to list answers, which the
forgejo client reads to page; test code only, no production file changes.
2026-11-17 00:26:27 +01:00
iris
181ef5f421 the builder reads an agent's icon from its config and the controller writes the swarm's copy 2026-11-16 23:01:08 +01:00
maia
6b3e1f0fb2 revoking a linked Matrix account also deletes its key-backup passphrase; a plain unlink keeps it for a relink 2026-11-16 22:49:16 +01:00
atlas
87dc4c5533 lock the service forge accounts out of creating organizations 2026-11-16 21:40:02 +01:00
atlas
df3fc02279 keep the signing policy on a role rewrite through one tested helper; route helper for build_app 2026-11-16 20:31:18 +01:00
atlas
910f9a6f50 gate ssh signing per agent: ssh permission, signing policy on the login role, ca key endpoint 2026-11-16 20:31:18 +01:00
atlas
299b922039 disable a destroyed agent's identity entity and delete its login role 2026-11-16 17:09:08 +01:00
iris
5175d3663e swarm: set the fresh-session threshold per agent 2026-11-16 10:50:13 +01:00
iris
fb9d4b5040 swarm: /clear starts an agent's next turn on a fresh session 2026-11-16 03:21:20 +01:00
damocles
51283b8cb1 swarm-controller: tests that the config repo grant is read and never lowers a write an operator made 2026-11-16 01:34:25 +01:00
damocles
07c66e3a1c agents get read, not write, on their own agent-configs repo; an existing grant is left alone 2026-11-16 01:34:25 +01:00
iris
b239500f88 swarm: an agent's open todos, mirrored to the queue and served by the controller 2026-11-16 01:21:52 +01:00
atlas
1edeb5c55d agents get a per-agent repo limit in their permissions record, orgs are locked
max_repos (default 0, 0..=100) lives in the agent's agent-permissions record and is edited on its permissions panel. The controller applies each agent's own value as max_repo_creation at CreateForgeUser and to existing accounts on change, restart and every five minutes; agent accounts may not create organizations.
2026-11-16 01:21:25 +01:00
damocles
dc0d08b7fb add a /clear-todos command that marks the agent's todos done 2026-11-16 01:06:02 +01:00
atlas
6d968c7fe6 forge-client: take the token as a string, drop TokenSource and StaticToken 2026-11-15 23:22:48 +01:00
atlas
a77131ca3f swarm-controller, swarm-ci-metrics: build forge clients through forge-client 2026-11-15 23:02:55 +01:00
iris
687683a4f0 swarm-controller: restore the commands route's 200 and 503 doc text 2026-11-15 20:05:55 +01:00
iris
05fef7926f swarm-controller: the commands route's 503 is only an unreachable queue 2026-11-15 20:05:55 +01:00
iris
8f11a38d17 swarm: the commands and skills an agent's message box offers
GET /api/agents/{name}/commands answers with the swarm's own commands, a table
in the controller, then the skills the agent's harness published to its key of
the agent-commands bucket. The published part is untrusted and cut down: plain
names only, no repeats, never a command's name, a capped list and one short line
per description. The agent credential may publish its own key. Nothing publishes
yet; the harness half and the swarm UI menu follow.
2026-11-15 20:05:54 +01:00
iris
06c338ff40 swarm-controller: say what entry_of does 2026-11-15 19:51:37 +01:00
iris
5de20f31dd swarm: list an agent's bash tasks from their published status
GET /api/agents/{name}/bash-tasks reads the agent's keys of the bash-task-status
bucket and reports each task's state, command and times, with a live task whose
daemon stopped reporting as stale. The swarm UI shows them in a background tasks
section of the agent card, running ones first. The task output stays unread.
2026-11-15 19:51:37 +01:00
iris
1779fa0568 swarm: the contract for an agent's bash task status and output
A status key per task in the bash-task-status bucket and the task's output rows
in a per-agent stream, kept apart as for subagents. The controller creates the
bucket and the streams, and the agent credential may publish its own keys and
subjects. Nothing publishes yet; the bash MCP half follows.
2026-11-15 18:22:16 +01:00
damocles
7dd988a9e8 rustfmt the soft context limit change 2026-11-15 17:21:13 +01:00
damocles
1e03979836 swarm: a soft context limit per agent, as a percent of the window, applied at turn end 2026-11-15 17:21:13 +01:00
iris
7122084850 swarm-controller: test how a subagent's status becomes its list entry
The running, stale and finished rule, the status deciding the entry over the
newest row, and the fallback to the row when a subagent has no status.
2026-11-15 17:17:10 +01:00
iris
e9bc28fe2f swarm: list subagents from their published run state
The subagents list reads each subagent's status from the subagent-status
bucket and reports its state, when it began and the exit status. A subagent
with no status keeps the newest-row lookup, so an older daemon lists as before.
The swarm UI uses the state when there is one and the row-age guess otherwise.
2026-11-15 17:17:10 +01:00
iris
91cf4d2ae1 icons for the swarm's own forge accounts, and a default agent icon
The builder, ci-metrics and review-classifier forge accounts get an avatar: an
icon each in a hexagonal frame, the hyperhive logo when one is missing. The
controller sets them with a short-lived write:user token it mints for the
account, since only an account can set its own avatar.

An agent with no icon of its own shows a default agent icon in the swarm UI, a
robot head in a round frame, instead of the dimmed hyperhive mark.
2026-11-15 17:14:16 +01:00
iris
c7d7f0df55 swarm: subagent-status KV bucket, the run state of each subagent
One key per subagent (<agent>.<subagent>) holding running/finished, since,
exit, model, effort and the publish time. The controller creates the bucket,
and the agent credential may publish its own keys. Nothing reads or writes
it yet; the daemon publisher and the controller list follow.
2026-11-15 15:36:12 +01:00
argus
c9c2e75091 review classifier: a nix option sits in the tree that fits it
A negative rule for options added or moved under services.hyperhive: swarm.*
holds swarm-wide facts that are the same on every host, deploy.* holds this
host's own deployment decisions grouped under the deployed component, and a
per-host setting that lands under swarm.* or under another module's namespace
while configuring a component deploy.* names is in the wrong tree. Read-only
outputs, internal options and a rename into the right tree are exempt. The
rules-file test lists the new name.
2026-11-15 15:34:12 +01:00
atlas
4bd02ea14d agents keep their github token in /run, fetched on every start, not in the state dir 2026-11-15 14:08:57 +01:00
atlas
adc61c9043 remove the swarm wireguard mesh; tombstone its options 2026-11-15 02:17:44 +01:00
damocles
7beb1193f4 swarm-controller: archive a destroyed agent's config repo, unarchive it when the name is created again 2026-11-14 13:29:39 +01:00
atlas
49266e4410 remove what no longer has a reader: build-log store, dashboard sent/delivered events, graph resource dep 2026-11-13 10:58:49 +01:00
damocles
c66832febf swarm-controller: stop minting the per-hive matrix sender account and token nothing reads 2026-11-12 15:38:34 +01:00
atlas
d8703f40dc destroying an agent clears its per-agent archetype-flow switch-offs 2026-11-11 21:40:17 +01:00