Commit graph hyperhive/docs
Author SHA1 Message Date
damocles
d31a723daf feat(#550): add depends_on to queue entries for explicit dep tracking 2026-06-04 17:39:31 +02:00
damocles
41eb3f806c refactor: remove hyperhive.role option — there is only one role: agent 2026-06-04 14:31:44 +02:00
damocles
d35408a18d docs: remove stale role field from AgentMeta in conventions.md 2026-06-04 14:30:27 +02:00
damocles
be8d8e48bf docs(bash): document wait_seconds param on run + status 2026-06-04 13:51:39 +02:00
damocles
60628fbb13 docs(tools/bash): fix incorrect execution tool group claims 2026-06-04 13:51:39 +02:00
damocles
9c1c4f62fb fix: add approval kind to cancel_loose_end docs; drop stale role comment in mcp.rs; fix system.md approval-cancel description 2026-06-04 13:51:39 +02:00
damocles
78a00d1258 docs(#1251): split MCP tool docs into docs/tools/ sub-mds by feature 2026-06-04 13:51:39 +02:00
damocles
cccb055245 docs: remove stale conflict marker from turn-loop.md 2026-06-04 12:15:03 +02:00
damocles
e58ead4329 fix: address argus+mara review on #1243 — stale docs, MANAGER_DEFAULT refs, ruth migration 2026-06-04 12:15:03 +02:00
damocles
f56b272a23 remove Role::Manager + ManagerSurface + Flavor::Manager — there is only one role: agent 2026-06-04 12:15:03 +02:00
atlas
6fab0d7f1a docs: update gateway.md — nginx reload goes through hive-priv
Reflect the fix from the companion Rust change: the nginx reload/start
is now routed through hive-priv (root) instead of calling
systemd-run --machine= directly from unprivileged hive-c0re.
Document the state-aware dispatch (active→reload, failed→reset+start,
other→start).
2026-06-04 09:51:49 +02:00
damocles
c634dab2a6 refactor: unify AgentServer + ManagerServer into HiveServer {socket, flavor} 2026-06-04 00:20:17 +02:00
lexis
1698372572 docs: bash_run timeout now fully optional, no default
PR #1223 removed the default 180s timeout. timeout_secs is now fully
optional: pass a value for a deadline, or omit for no timeout (natural exit).
2026-06-04 00:03:55 +02:00
damocles
1353fbaf17 docs: add list_containers to agent lifecycle tools in turn-loop.md 2026-06-03 23:05:33 +02:00
lexis
e5bcd16daf docs: turn-loop.md agent lifecycle + config request tools (follow-up to #1226) 2026-06-03 22:55:50 +02:00
atlas
9209094397 fix: move core-token out of hive-ci container (host-side prefetch service) 2026-06-03 22:18:53 +02:00
atlas
d726a0d875 docs: clarify nix eval is not fully sandboxed (IFD, fetchGit can reach network) 2026-06-03 21:52:59 +02:00
atlas
e92cfe7e1a docs: add security warning for unsandboxed CI builds and trusted-contributor scope 2026-06-03 21:52:59 +02:00
damocles
f5351eb59c fix(#1194): update Execution tool names + frontend + docs 2026-06-03 21:20:49 +02:00
atlas
fb93cbf5c2 feat: add tls.acme mode — nginx inside container manages Let's Encrypt
per mara's suggestion: instead of bind-mounting operator certs, let
nginx handle ACME directly inside the gateway container.

- tls.acme.enable: lets nginx obtain + renew via HTTP-01 challenge
- tls.acme.email: ACME account contact (required when enable=true)
- security.acme in container config when acme.enable
- hasTls includes acme.enable → https, httpsPort listen, firewall
- mutual exclusion assertions: acme vs selfSignedTls vs certDir
- docs/gateway.md: four-mode TLS table + ACME section

typical setup:
  selfSignedTls = false; openFirewall = true;
  tls.acme = { enable = true; email = "admin@example.com"; };
2026-06-03 16:46:52 +02:00
atlas
6c4b47a7ec docs: note ACME key file permissions for tls.certDir
security.acme defaults key to 0640 root:acme — nginx in the container
can't read it. operator must set group = "nginx" on the ACME cert.

addresses argus yellow note on PR #1153.
2026-06-03 16:46:52 +02:00
atlas
44122c66de feat(#594): gateway operator-cert TLS mode (tls.certDir)
add services.hyperhive.gateway.tls.certDir option: operators with a
CA-signed cert (Let's Encrypt, corporate CA) point at the ACME output
dir instead of using the auto-generated self-signed cert.

- tls.certDir: host path bind-mounted r/o at /run/hive-tls/ in gateway
- tls.certName / tls.keyName: filenames within certDir (default: cert.pem / key.pem, matches nixpkgs security.acme layout)
- hasTls = selfSignedTls || certDir != null: publicScheme=https in both cases
- assertion: selfSignedTls=true + certDir set together is an error
- openFirewall: httpsPort opened in both TLS modes
- docs/gateway.md: TLS modes table + operator-cert section
- docs updated in swarm.md peer config reference in the cert TLS section

when using operator cert, swarm peers can omit certFingerprint —
standard CA bundle handles trust automatically.
2026-06-03 16:46:52 +02:00
atlas
806d0e4a61 fix: use forge domain URL + open 80/443 for isolated agents
when isolateContainers=true, isolated agents have dnsmasq as their
resolver — forge.<domain> resolves to bridgeIp. route HIVE_FORGE_URL
through nginx on port 80 instead of exposing the raw forge port.

- HIVE_FORGE_URL: http://<forge.domain> when isolated (nginx proxies)
- bridge firewall: open 80+443 for agents to reach nginx (gateway)
- remove forge-specific httpPort rule (no longer needed)
- update docs/gateway.md + docs/network.md

per mara's review comment on PR #1150.
2026-06-03 16:33:10 +02:00
atlas
c97120f016 fix: forge URL + firewall for isolateContainers=true
When containers run in private netns (isolateContainers=true), host
loopback is unreachable so HIVE_FORGE_URL=http://127.0.0.1:3000 breaks.

- nix/modules/hive-network.nix: when isolateContainers is on + forge
  is enabled, open forge.httpPort on the bridge interface so agents
  can reach forgejo at bridgeIp:httpPort (forgejo binds 0.0.0.0)
- nix/modules/hive-c0re.nix: HIVE_FORGE_URL switches to bridge IP
  when network.enable && isolateContainers; loopback path retained
  when isolateContainers=false
- docs/network.md: add Forge access + Forge URL rows to effects table
- docs/gateway.md: rewrite HIVE_FORGE_URL section for both modes
2026-06-03 16:33:10 +02:00
atlas
89609aaa6a feat(#569): wireguard inter-hive mesh option
Add opt-in WireGuard mesh support to services.hyperhive.swarm:

- swarm.peers.<domain>.wireguardPublicKey — peer's wg public key
- swarm.peers.<domain>.wireguardEndpoint  — peer's UDP endpoint (optional)
- swarm.peers.<domain>.wireguardAddress   — peer's mesh IP with prefix

- swarm.wireguard.enable           — bring up wg-hive interface
- swarm.wireguard.privateKeyFile   — path to host's wg private key
- swarm.wireguard.address          — this host's mesh IP/prefix
- swarm.wireguard.listenPort       — UDP listen port (default 51820)
- swarm.wireguard.persistentKeepalive — keepalive seconds (default 25)

When enabled, generates networking.wireguard.interfaces.wg-hive with
one peer entry per mesh-enabled swarm.peers entry. Opens listenPort
UDP on the host firewall. Adds wireguard_address to HYPERHIVE_PEERS
JSON so hive-c0re can use mesh IPs for intra-swarm routing.

Assertions guard against enable=true without privateKeyFile or address.

Also refactors networking.firewall.allowedTCPPortRanges from the
nested attrset form (which conflicted with the new allowedUDPPorts
line) to the per-attribute form.

docs/swarm.md: adds WireGuard setup section with key generation
commands, two-hive config example, NAT/keepalive notes.
2026-06-03 15:19:16 +02:00
damocles
0ac6028844 docs(#14): update network isolation docs - remove stale manager special-case claim 2026-06-03 12:31:54 +02:00
atlas
302e5e2869 docs: remove forward-looking issue reference from network.md 2026-06-03 11:19:29 +02:00
atlas
b89c5f5334 network: fix stale assertion messages; move prose to docs/network.md 2026-06-03 11:19:29 +02:00
iris
a8ffdf31e0 docs(#1014): update stale root→ruth references in conventions, approvals, agent-hierarchy 2026-06-02 22:48:10 +02:00
damocles
eae0e875cf feat(#1086): serialize perm changes through rebuild queue
add QueueKind::PermChange — dashboard tool-group and capability
handlers no longer write the shared JSON files inline. instead they
enqueue a PermChange entry; the FIFO worker applies the file write
then calls rebuild_agent so the updated env var takes effect.

concurrent batch-apply actions for different agents previously raced
on tool-groups.json / capabilities.json (last write wins, earlier
change silently dropped). serialising through the queue prevents this.

dedup check extended with perm-type discriminant so tool-groups and
capabilities changes for the same agent are kept as distinct entries
and never collapse into one slot.
2026-06-02 16:42:22 +02:00
damocles
dce2bd0686 feat(#343): route container restart through rebuild queue 2026-06-02 13:34:24 +02:00
iris
0da736f2a1 fix(docs): web_tools is a tool group, not a capability
Remove web_tools from the C4P4B1L1T13S table in dashboard.md and add
it to the T00L GR0UPS section with a note that it gates Claude built-ins
rather than MCP tools. Fix turn-loop.md to say 'tool-group-gated' and
'web_tools tool group' throughout.
2026-06-02 12:47:18 +02:00
iris
91ad9877dc docs(web-ui): add P3RM1SS10NS to dashboard tab list in index 2026-06-02 12:47:18 +02:00
iris
de8c446a3a docs: document web_tools capability in turn-loop and dashboard 2026-06-02 12:47:18 +02:00
iris
834d9cb2c4 docs(web-ui): update CSS bundle description for split stylesheet layout 2026-06-02 12:47:18 +02:00
iris
f55d3baa0a docs(web-ui): add P3RM1SS10NS to tab strip list and URL hash list 2026-06-02 12:47:18 +02:00
iris
b3ccd1500c docs(web-ui): document P3RM1SS10NS tab and tool-groups/capabilities endpoints 2026-06-02 12:47:18 +02:00
iris
5946c8fbd8 docs(gotchas): update stale 'claude's Bash tool' reference to bash_run
The Bash built-in is now denied; bash_run is the correct MCP tool.
2026-06-02 12:46:53 +02:00
iris
1e04047059 docs(conventions): add Capabilities section parallel to Tool groups
Capabilities were added with the permissions tab but conventions.md only
documented tool groups. Adds a full Capabilities section covering: the
known capabilities table, config storage path, HIVE_CAPABILITIES env var
injection, runtime resolution, operator-only grant constraint, and the
pattern for adding a new capability.
2026-06-02 12:46:12 +02:00
iris
14368b2e09 docs(dashboard): add L0GS page section documenting three sub-tabs
/logs.html was undocumented — only mentioned in passing in API
endpoint lists. Adds a proper section covering BUILD / AGENT /
SYSTEM sub-tabs, their API endpoints, and behaviour.
2026-06-02 12:45:42 +02:00
iris
30c8459add docs(persistence): expand meta/ dir section to list config JSON files
The meta/ section only described the flake. Added entries for
topology.json, tool-groups.json, and capabilities.json — the three
system-level config files also committed there — with their writers,
readers, and injected env vars.
2026-06-02 12:43:59 +02:00
damocles
cbd14e9cd0 fix(#1066): retry turn once on 401 before parking for re-login 2026-06-02 12:43:41 +02:00
iris
ae695931ce chore(agent): move screen.html inline styles into agent.css; add --blue/--yellow/--subtext0 to palette 2026-06-02 12:43:11 +02:00
damocles
88f22065b0 feat(#1058): disallow built-in Bash; remove allowedBashPatterns; prompt sweep 2026-06-02 01:14:24 +02:00
atlas
9d816431dc fix(#981): validate runner credentials on every boot, purge stale .runner
hive-ci-register.service now runs unconditionally on every boot (not
just when .runner is absent). Before fetching a registration token it
validates existing .runner credentials via the forge admin API:
- 200: runner still registered, write dummy token and exit
- 404: runner deleted from forge, purge .runner and re-register
- 000: forge unreachable, keep credentials (runner surfaces the error)
- other non-200 or malformed .runner: purge and re-register

Removes ConditionPathExists so stale credentials from a wiped forge
no longer block the runner indefinitely. Updates docs/ci.md to match.
2026-06-02 00:27:47 +02:00
atlas
4bd0228de0 docs(gateway): update Basic auth section for fixed htpasswd path
Remove stale htpasswdFile option from nix example (option no longer
exists). Update hivectl command examples to drop --file flag (now
optional with standard default). Add description of the fixed path
and how it's exposed inside the container.
2026-06-02 00:26:10 +02:00
atlas
4bff450343 feat(gateway): hivectl gateway user management + fix htpasswdFile assertion
Add `hivectl gateway {create-user,delete-user,list-users}` subcommands for
managing htpasswd files used by gateway Basic auth. Pure Rust bcrypt
(cost 12, $2y$ prefix nginx accepts). No external htpasswd binary required.

Also fix the NixOS module assertion: `cfg.auth ? htpasswdFile` is always
true in the module system (declared options always exist as keys); switch
to `nullOr path; default = null` + `!= null` check so the assertion
actually fires with a useful error when enable=true but no file is set.
Guard bind-mount and nginx config against null to prevent eval errors.

Update docs/gateway.md to show hivectl commands instead of raw htpasswd.
2026-06-01 23:25:28 +02:00
atlas
25d2951d1e feat(gateway): htpasswd Basic auth — close #1010
Replaces the earlier PAM+binary approach with nginx's built-in
`auth_basic` module. No new binary, no new systemd service, no PAM.

New option `services.hyperhive.gateway.auth`:
- `enable` — off by default
- `htpasswdFile` — host path to an htpasswd file (required when enable)
- `realm` — WWW-Authenticate realm string (default "hyperhive");
  restricted to `strMatching "[^\"$]*"` to prevent nginx config injection

When enabled:
- the parent directory of `htpasswdFile` is bind-mounted read-only
  into the gateway container at `/run/gateway-auth/`
- the `"/"` proxy location gets `auth_basic` + `auth_basic_user_file`

Create credentials: `htpasswd -Bc /path/to/file alice` (BCrypt).
See `docs/gateway.md` ("HTTP Basic auth") for the full setup guide.
2026-06-01 23:24:47 +02:00
iris
81607aca26 docs: add CSS custom properties reference (docs/css-vars.md)
Lists all variables declared in base.css with their hex values,
Catppuccin Mocha names, and intended use. Includes a common-mistakes
table mapping the wrong names (--text, --mauve, --surface0/1/2, etc.)
to the correct ones, plus a usage guide for the most common patterns
(dropdowns, hover states, active tabs, badges).
2026-06-01 19:55:01 +02:00
damocles
68cc433ac9 fix(#977): add MANAGER_CONTAINER=h-root, migrate root container name 2026-06-01 18:32:19 +02:00