Persistence and config changes

What survives what, and how a change to an agent's config reaches it.

Persistence

The short answer to "does anything disappear": destroying an agent keeps its state, purging it doesn't.

Beyond that:

The tables, state directories, mounts and migrations behind this are in persistence.md.

Config changes

A config change is a pull request on the agent's config repo, agent-configs/<name>. No tool exists for it: opening the PR is the request.

  1. The agent clones its config repo, edits it (agent.nix is the entry point) and opens the PR with hive-forge pr create --agit. It has read access to the repo and no push access, so it can't push a branch or merge its own config PR. An agent can propose a change to another agent's config the same way.
  2. You review the PR on the forge, with its diff, comments and CI status, and merge it there. Merging needs membership of the operators team in agent-configs. The team starts empty: add each operator by hand in the forge UI.
  3. The merge deploys. The swarm controller finds the hive that runs the agent and tells it to rebuild.

A merge runs no evaluation check. A merged config that doesn't evaluate or build fails the rebuild, and the agent's rebuilds keep failing until a fix merges. A failed rebuild shows on the hive like any other. A merge whose webhook never reaches the controller deploys nothing.

You create a brand-new agent at swarm level (swarmctl agent create, or the swarm UI), not from a hive. The controller seeds its config repo with a default agent.nix, and every later change is a PR like any other. An agent created from an archetype gets no config repo: the swarm builds it from the archetype's module.

The full path, the meta flake, deploy markers, startup migrations, the root container, the system messages hive-c0re sends and autoupdate: config-changes.md.