fix: bug: docker/agents/entrypoint.sh credential check looks for credentials.json but Claude writes .credentials.json — every boot logs a misleading WARNING (#673)
All checks were successful
ci/woodpecker/push/ci Pipeline was successful
ci/woodpecker/pr/ci Pipeline was successful

This commit is contained in:
Claude 2026-04-11 16:59:42 +00:00
parent 3f524ae06f
commit 8fe985ea51

View file

@ -122,7 +122,7 @@ log "Claude CLI: $(claude --version 2>&1 || true)"
# auth method is active so operators can debug 401s.
if [ -n "${ANTHROPIC_API_KEY:-}" ]; then
log "Auth: ANTHROPIC_API_KEY is set — using API key (no OAuth rotation)"
elif [ -f "${CLAUDE_CONFIG_DIR:-/home/agent/.claude}/credentials.json" ]; then
elif [ -f "${CLAUDE_CONFIG_DIR:-/home/agent/.claude}/.credentials.json" ]; then
log "Auth: OAuth credentials mounted from host (${CLAUDE_CONFIG_DIR:-~/.claude})"
else
log "WARNING: No ANTHROPIC_API_KEY and no OAuth credentials found."