# Fleet tools Seat lifecycle tools for a Mosaic fleet. Paths are relative to `packages/mosaic/framework/tools/fleet/` (deployed to `~/.config/mosaic/tools/fleet/`). | Script | Purpose | | ----------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- | | `start-agent-session.sh` | launch, stop, or attach a roster-driven agent session (reads `.env.generated`, honours `MOSAIC_TMUX_SOCKET`) | | `seat-logins.sh` | project seat tokens into `tea` logins named `-` (dry-run by default, `--apply`, `--adopt`) | | `mint-seat-credential.sh` | create the Gitea account for a seat on every configured instance, mint a token, write the seat's credential slot, then project it into `tea` | | `start-interaction-service.sh`, `print-interaction-effective-policy.sh`, `start-tmux-holder.sh` | operator interaction service and tmux holder | ## Onboarding a seat's credential ``` MOSAIC_ADMIN_SEAT= mint-seat-credential.sh ``` - The admin token is read from `$MOSAIC_BRAIN_HOME/fleet/agents//secrets/gitea--.token`. It is never printed. - Instances default to the map shared with `seat-logins.sh`; `MOSAIC_GITEA_INSTANCES="a b"` limits the set and `MOSAIC_GITEA_URL_` overrides a server URL. - The seat slot is written from the mint response: `.token`, `.scopes` (what was granted), `.principal`, each mode 600. - `tea` absent is a warning, not a failure: REST-path wrappers work with the token alone. - Regression suite: `test-mint-seat-credential.sh` (hermetic, mock curl, no network).