Skip to content

Agent credentials on Docker-less instances: paste credentials + interactive login on the remote runtime #3863

Done

Description

@integry

Problem

On a ProPR instance without a local Docker daemon, agent credentials can't be set up from the UI. That covers a Fly dashboard launch (#3827 / PR #3852) and any instance whose agents run on Sprites or Fly Machines. Found live on 2026-11-27 on a dashboard-launched instance (propr-dash-3852, agent runtime Sprites):

  • Coding agents → claude → "Log in to claude" fails at once:
    Agent image "propr/agent:bundle-…" is unavailable and could not be pulled: failed to connect to the docker API at unix:///var/run/docker.sock … no such file or directory
    packages/api/services/agentLoginSessionManager.ts always runs the login CLI in a local Docker container (docker image inspect / pull / create).
  • The agent card shows "Agent image preparation failed". packages/api/services/agentHealthCheck.ts checks and prepares the local Docker image even though agents run remotely.
  • The agent dialog (propr-ui/src/pages/SettingsPage/AgentConfigModal.tsx) has an API key field only for Vibe (MISTRAL_API_KEY). Claude and Codex have no way to enter credentials without an interactive login.

So far the remote runtimes have only been exercised with credential files injected through the deploy env (FLY_E2E_APP_ENV → the managed credential store). The UI path was never covered.

Required behavior

  1. Paste credentials (works everywhere, including with Docker). In the agent dialog, each provider gets a way to enter credentials without an interactive login. They're stored in the agent configuration's managed credential store, in the files each provider manifest declares (credentials/providerManifests.ts), so both remote runtimes pick them up unchanged.

  2. Interactive login on the remote runtime. When the instance's agent runtime is Sprites or Fly Machines and there's no usable local Docker, "Log in to " runs the provider's login CLI on that runtime instead:

    • Sprites: a short-lived Sprite (or exec in a fresh one) with a TTY over the Sprites API.
    • Fly Machines: an ephemeral Machine from the agent image, with exec / console.

    The UI keeps streaming the session output and accepting input as it does today. On success, copy the credential files the manifest declares back into the managed store, then destroy the Sprite or Machine. Respect the Free Plan limits (3 Machines / 3 Sprites) and the existing PROPR_FLY_MACHINES_MAX cap. Fail with a clear message when no slot is free.

  3. Health check by runtime. With a remote agent runtime, don't prepare or check the local Docker image. Report the remote runtime's readiness instead: token valid, image or CLI version resolvable. Never show "Agent image preparation failed" there.

  4. Local Docker instances: behavior unchanged.

Acceptance

  • Unit and integration tests for each path, including the case with no Docker socket and a remote runtime.

  • Live, on a Fly-launched instance (the dashboard launch from [3827 by Claude Opus 5.5] Deploy ProPR from the Fly.io dashboard (Launch an App → From GitHub), with first-visit setup #3852, or propr deploy fly):

    • (a) Claude via a pasted API key or setup-token, an issue labelled AI → a PR, on both Sprites and Fly Machines;
    • (b) the interactive Claude login on Sprites completes and the following run uses those credentials;
    • (c) the agent card shows healthy, with no image-preparation error.

    Add run links to the PR.

  • Docs: setup-fly.md and the agent-configuration docs explain both paths.

Activity

  1. propr-dev commented on Nov 27, 2026

    @propr-dev
    Contributor

    🤖 AI processing has started for this issue using claude agent with claude-opus-5-5 model.

    I'll analyze the problem and work on a solution. This may take a few minutes.

    Processing Details:

    • Agent: claude
    • Model: claude-opus-5-5
    • Branch: 3863/claude-opus-5-5-agent-credentials-on-dock-20261127-2255-6h9
    • Base Branch: 3758-epic-runtime-abstraction-sc0
    • Worktree: issue-3863-20261127-2255-claude-opus-5-5-6h9

    🔍 Track Task Execution

  2. propr-propr-dash-3852-fly-dev commented on Nov 27, 2026

    @propr-propr-dash-3852-fly-dev

    🤖 AI processing has started for this issue using claude agent with claude-opus-5-5 model.

    I'll analyze the problem and work on a solution. This may take a few minutes.

    Processing Details:

    • Agent: claude
    • Model: claude-opus-5-5
    • Branch: 3863/claude-opus-5-5-agent-credentials-on-dock-20261127-2255-q5i
    • Base Branch: 3758-epic-runtime-abstraction-sc0
    • Worktree: issue-3863-20261127-2255-claude-opus-5-5-q5i

    🔍 Track Task Execution

  3. integry commented on Nov 27, 2026

    @integry
    OwnerAuthor

    Design note from the user: login is needed only rarely, so a short-lived Sprite or Fly Machine for the interactive login is fine. Don't add the provider CLIs to the control plane image for this. Destroy the login Sprite or Machine once the credential files are copied back.

  4. propr-propr-dash-3852-fly-dev commented on Nov 27, 2026

    @propr-propr-dash-3852-fly-dev

    🤖 AI processing has started for this issue using claude agent with claude-opus-5-5 model.

    I'll analyze the problem and work on a solution. This may take a few minutes.

    Processing Details:

    • Agent: claude
    • Model: claude-opus-5-5
    • Branch: 3863/claude-opus-5-5-agent-credentials-on-dock-20261127-2257-zlz
    • Base Branch: 3758-epic-runtime-abstraction-sc0
    • Worktree: issue-3863-20261127-2257-claude-opus-5-5-zlz

    🔍 Track Task Execution

  5. integry commented on Nov 28, 2026

    @integry
    OwnerAuthor

    Also seen on a Docker-less control plane (Dockerfile.app.prod image, launch entrypoint): the daemon's idle worktree sweep and container mount checks call docker ps and log warnings like docker ps failed: failed to connect to the docker API at unix:///var/run/docker.sock and Idle worktree sweep reclaimed nothing and container mount authority failed. When the agent runtime is remote and no Docker socket exists, skip the Docker-based sweep and mount checks, or log once at startup, instead of repeating warnings.

  6. integry commented on Dec 1, 2026

    @integry
    OwnerAuthor

    Done in #3865, which merged into the runtime epic; the epic merged into main with #3774 and ships in 0.9.4.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions