Concierge boot-install can't authenticate the gitea plugin fetch (404) — no GIT_HTTP creds; needs MOLECULE_TEMPLATE_REPO_TOKEN auth [next layer after #872] #3065

Closed
opened 2026-06-19 05:35:19 +00:00 by molecule-code-reviewer · 0 comments
Member

Gap (next layer after #872): concierge boot-install can't AUTH the gitea plugin fetch → 404 → no create_workspace

After CP #872 (RFC #3045, retire the special image) the concierge now runs the standard claude-code image and its plugin boot-install runs — verified live on a fresh staging concierge (box image = workspace-template-claude-code). But the plugin fetch fails:

curl: (22) The requested URL returned error: 404
[plugins] fetch/extract failed: gitea://molecule-ai/molecule-ai-plugin-molecule-platform-mcp#main
::warning::GIT_HTTP_USERNAME or GIT_HTTP_PASSWORD not set; skipping ~/.netrc setup. Gitea curl calls will need an alternative safe-auth method.

Root cause (isolated)

  • The repo + ref + URL are correct: GET /api/v1/repos/molecule-ai/molecule-ai-plugin-molecule-platform-mcp/archive/main.tar.gz returns HTTP 200 with a valid token (private repo, main, non-empty).
  • The box's boot-install gitea curl is unauthenticated: scripts/setup-gitea-netrc.sh (runtime image) needs GIT_HTTP_USERNAME/GIT_HTTP_PASSWORD, injected by core applyAgentGitHTTPCreds from /etc/molecule-bootstrap/personas/<role>/token. The concierge has no persona token file (it's not a fleet persona) → no GIT_HTTP creds → netrc skipped → unauthenticated curl → 404 on the private plugin repo.
  • The box DOES hold MOLECULE_TEMPLATE_REPO_TOKEN (the read-only template/plugin fetch token) — but the shell boot-install doesn't use it for auth. (The Go gitea resolver plugins/gitea.go DOES use that token, but the on-box boot-install is a separate shell path that relies on netrc.)
  • seo-all installs because seo-agent boxes get persona GIT_HTTP creds (or the seo-agent template repo is reached differently); the concierge gets neither.

Fix (pick one)

  • (core, smallest) For the concierge, set GIT_HTTP_USERNAME + GIT_HTTP_PASSWORD from MOLECULE_TEMPLATE_REPO_TOKEN in the concierge provision env (e.g. conciergePlatformMCPEnv / applyConciergeProvisionConfig) so setup-gitea-netrc.sh authenticates the plugin fetch. The token is read-only (safe; survives the SCM-write denylist via the GIT_HTTP_* names).
  • (runtime image, most general) setup-gitea-netrc.sh falls back to MOLECULE_TEMPLATE_REPO_TOKEN (as password, with a fixed username) when GIT_HTTP_* / GITEA_* are absent — fixes plugin-fetch auth for ANY plugin-using workspace, not just the concierge.

Chain status (concierge → create_workspace)

ECR cross-account (infra, fixed) → declares gitea:// plugin (#3049, merged) → restart no longer re-stubs (#3055, merged) → runs plugin-capable claude-code image (#872, merged+verified) → THIS: boot-install auths the gitea plugin fetch → plugin installs → MCPServerAdaptor wires mcpServers.molecule-platformcreate_workspace. This is the next (and hopefully last-but-one) link; Task #52 still open.

Refs RFC #3045, #872, core#3063, #3049.

## Gap (next layer after #872): concierge boot-install can't AUTH the gitea plugin fetch → 404 → no create_workspace After CP #872 (RFC #3045, retire the special image) the concierge now runs the **standard claude-code image** and its plugin boot-install **runs** — verified live on a fresh staging concierge (box image = `workspace-template-claude-code`). But the plugin fetch fails: ``` curl: (22) The requested URL returned error: 404 [plugins] fetch/extract failed: gitea://molecule-ai/molecule-ai-plugin-molecule-platform-mcp#main ::warning::GIT_HTTP_USERNAME or GIT_HTTP_PASSWORD not set; skipping ~/.netrc setup. Gitea curl calls will need an alternative safe-auth method. ``` ## Root cause (isolated) - The repo + ref + URL are correct: `GET /api/v1/repos/molecule-ai/molecule-ai-plugin-molecule-platform-mcp/archive/main.tar.gz` returns **HTTP 200 with a valid token** (private repo, main, non-empty). - The box's boot-install gitea curl is **unauthenticated**: `scripts/setup-gitea-netrc.sh` (runtime image) needs `GIT_HTTP_USERNAME`/`GIT_HTTP_PASSWORD`, injected by core `applyAgentGitHTTPCreds` from `/etc/molecule-bootstrap/personas/<role>/token`. The **concierge has no persona token file** (it's not a fleet persona) → no GIT_HTTP creds → netrc skipped → unauthenticated curl → **404** on the private plugin repo. - The box DOES hold `MOLECULE_TEMPLATE_REPO_TOKEN` (the read-only template/plugin fetch token) — but the shell boot-install doesn't use it for auth. (The Go gitea resolver `plugins/gitea.go` DOES use that token, but the on-box boot-install is a separate shell path that relies on netrc.) - `seo-all` installs because seo-agent boxes get persona GIT_HTTP creds (or the seo-agent template repo is reached differently); the concierge gets neither. ## Fix (pick one) - **(core, smallest)** For the concierge, set `GIT_HTTP_USERNAME` + `GIT_HTTP_PASSWORD` from `MOLECULE_TEMPLATE_REPO_TOKEN` in the concierge provision env (e.g. `conciergePlatformMCPEnv` / `applyConciergeProvisionConfig`) so `setup-gitea-netrc.sh` authenticates the plugin fetch. The token is read-only (safe; survives the SCM-write denylist via the GIT_HTTP_* names). - **(runtime image, most general)** `setup-gitea-netrc.sh` falls back to `MOLECULE_TEMPLATE_REPO_TOKEN` (as password, with a fixed username) when `GIT_HTTP_*` / `GITEA_*` are absent — fixes plugin-fetch auth for ANY plugin-using workspace, not just the concierge. ## Chain status (concierge → create_workspace) ECR cross-account (infra, fixed) → declares gitea:// plugin (#3049, merged) → restart no longer re-stubs (#3055, merged) → runs plugin-capable claude-code image (#872, merged+verified) → **THIS: boot-install auths the gitea plugin fetch** → plugin installs → MCPServerAdaptor wires `mcpServers.molecule-platform` → `create_workspace`. This is the next (and hopefully last-but-one) link; Task #52 still open. Refs RFC #3045, #872, core#3063, #3049.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: molecule-ai/molecule-core#3065