claude-code: claude in the operator's zsh starts the agent's session where the machine names an agent account (hq ADR 0266)
mesh/merge-gate pass: builds claude-code → ace, g14, novox, shanks; no bus step; every machine composes with the change as it did without (4 of 4 compose)
mesh/repo-check pass: its merge-check.sh passed, each part in its toolchain: merge-check.sh (go), merge-check-typescript.sh (typescript)
mesh/delivery covered: a later merge that contains it was delivered: novox/mesh-catalog@e4edab3fd0eb (merged as c41c32cb into main, walk plan-17916298010…
mesh/merge-gate pass: builds claude-code → ace, g14, novox, shanks; no bus step; every machine composes with the change as it did without (4 of 4 compose)
mesh/repo-check pass: its merge-check.sh passed, each part in its toolchain: merge-check.sh (go), merge-check-typescript.sh (typescript)
mesh/delivery covered: a later merge that contains it was delivered: novox/mesh-catalog@e4edab3fd0eb (merged as c41c32cb into main, walk plan-17916298010…
Typing claude on the control node should start the session as the agent's own account, not as the operator. The controller fills no machine fact into shell code, so the account agents run as is written to /etc/claude-code/agent-account and the zsh code adds alias claude=claude-agent only when that file names an account other than the shell's own. Where agents run as the operator's account, nothing is added. claude-agent keeps running the real claude: exec sees no alias.
This commit is contained in:
@@ -26,6 +26,13 @@ And, for where the agent runs as an account of its own (hq ADR 0266):
|
||||
- `/usr/local/bin/claude-agent`, root's, `0755`: starts the agent as that account — `claude` itself when run
|
||||
as it, otherwise `sudo -iu <account> claude` through the operator's own sudo, carrying the guard's
|
||||
override only when it is set in the operator's shell.
|
||||
- `/etc/claude-code/agent-account`, root's, `0644`: the name of that account, the machine fact
|
||||
`agent-account`, for the shell to read — the controller fills no machine fact into shell code.
|
||||
- **`claude` in the operator's interactive zsh is `claude-agent`** where the machine names an agent account:
|
||||
zsh code in the login shell's `normal` slot (hq ADR 0204) reads that file and adds
|
||||
`alias claude=claude-agent` only when it names an account other than the shell's own. Where agents run as
|
||||
the operator's account the file names that account, and nothing is added. `claude-agent` still runs the
|
||||
real `claude`: an alias is a word of an interactive zsh, and neither `exec`, `sudo` nor its `sh` sees it.
|
||||
|
||||
## What it writes
|
||||
|
||||
|
||||
Reference in New Issue
Block a user