AOS --auth stages Codex credentials only, so Claude launches start logged out #968

Closed
opened 2026-08-07 04:59:01 +00:00 by coilyco-ops · 0 comments
Member

Observed

A standalone containerized launch composes the role bundle correctly and then fails to authenticate:

aos --role ai --agent claude --auth acompose -- claude -p --model claude-sonnet-5 ...
bundle verified: 40 skills // 122 files
projected 120 files into layout claude (home scope) under /home/aos
Not logged in · Please run /login
aos: docker run: exit status 1

Composition, projection, and the mount graph are all fine. Only the credential is missing.

Cause

docs/aos-codex-auth.md defines credential staging for Codex: environment names crossing by name, auth.json under CODEX_HOME, then the macOS Codex Auth Keychain record written to a private temporary file and mounted read-only. No equivalent path exists for Claude, so --auth is accepted for --agent claude and stages nothing.

Claude Code namespaces its macOS Keychain credential by a digest of CLAUDE_CONFIG_DIR, per docs/native-claude-credentials.md. The native launcher already solves this for host sessions by lending the host credential into the session-scoped service and harvesting it back. Containerized launches have no such bridge.

Consequence

Any Claude session in a clean context starts logged out. Verified independently of AOS: a plain claude -p with CLAUDE_CONFIG_DIR pointed at an empty directory also returns Not logged in.

The effect this surfaced in is evaluation evidence. Every committed record in agent-compose evaluations/latest/ is *-codex.yaml, because the Codex seat is the one that can run where host instructions are absent. A Claude-seat run must currently use the host home, where the global CLAUDE.md is in context. That is demonstrable: a plain claude -p in an empty directory answers "aos" and "she/her" with no bundle present, so a role case can pass on host instructions the bundle never supplied. See coilyco-flight-deck/agent-compose#240.

Options

  • Extend the native launcher's lend-and-harvest bridge to containerized launches, matching what Codex already does through its Keychain record.
  • Support ANTHROPIC_API_KEY discovery for --agent claude, mirroring the CODEX_API_KEY path. This also suits unattended runs, where OAuth is the wrong shape.
  • Fail closed instead: reject --auth with --agent claude and say the credential path is unimplemented, rather than starting a container that cannot authenticate.

The third is worth doing regardless of which of the first two is chosen, because the current failure appears only after image pull, composition, and projection have completed.

Boundary

Filed as a factual record by the AI Engineer seat from observed behavior. Deployment, launcher, and credential-handling decisions belong to DevOps and AOS.

## Observed A standalone containerized launch composes the role bundle correctly and then fails to authenticate: ``` aos --role ai --agent claude --auth acompose -- claude -p --model claude-sonnet-5 ... bundle verified: 40 skills // 122 files projected 120 files into layout claude (home scope) under /home/aos Not logged in · Please run /login aos: docker run: exit status 1 ``` Composition, projection, and the mount graph are all fine. Only the credential is missing. ## Cause [`docs/aos-codex-auth.md`](docs/aos-codex-auth.md) defines credential staging for Codex: environment names crossing by name, `auth.json` under `CODEX_HOME`, then the macOS `Codex Auth` Keychain record written to a private temporary file and mounted read-only. No equivalent path exists for Claude, so `--auth` is accepted for `--agent claude` and stages nothing. Claude Code namespaces its macOS Keychain credential by a digest of `CLAUDE_CONFIG_DIR`, per [`docs/native-claude-credentials.md`](docs/native-claude-credentials.md). The native launcher already solves this for host sessions by lending the host credential into the session-scoped service and harvesting it back. Containerized launches have no such bridge. ## Consequence Any Claude session in a clean context starts logged out. Verified independently of AOS: a plain `claude -p` with `CLAUDE_CONFIG_DIR` pointed at an empty directory also returns `Not logged in`. The effect this surfaced in is evaluation evidence. Every committed record in agent-compose `evaluations/latest/` is `*-codex.yaml`, because the Codex seat is the one that can run where host instructions are absent. A Claude-seat run must currently use the host home, where the global `CLAUDE.md` is in context. That is demonstrable: a plain `claude -p` in an empty directory answers "aos" and "she/her" with no bundle present, so a role case can pass on host instructions the bundle never supplied. See coilyco-flight-deck/agent-compose#240. ## Options * Extend the native launcher's lend-and-harvest bridge to containerized launches, matching what Codex already does through its Keychain record. * Support `ANTHROPIC_API_KEY` discovery for `--agent claude`, mirroring the `CODEX_API_KEY` path. This also suits unattended runs, where OAuth is the wrong shape. * Fail closed instead: reject `--auth` with `--agent claude` and say the credential path is unimplemented, rather than starting a container that cannot authenticate. The third is worth doing regardless of which of the first two is chosen, because the current failure appears only after image pull, composition, and projection have completed. ## Boundary Filed as a factual record by the AI Engineer seat from observed behavior. Deployment, launcher, and credential-handling decisions belong to DevOps and AOS.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
coilyco-flight-deck/agentic-os#968
No description provided.