Skip to content

Expose resolved Docker endpoint and failure reason in diagnostics#68

Draft
agustif wants to merge 2 commits intocoast-guard:mainfrom
agustif:af/docker-diagnostics
Draft

Expose resolved Docker endpoint and failure reason in diagnostics#68
agustif wants to merge 2 commits intocoast-guard:mainfrom
agustif:af/docker-diagnostics

Conversation

@agustif
Copy link
Contributor

@agustif agustif commented Mar 12, 2026

Summary

Draft follow-up for #65.

This PR improves diagnostics only:

  • records the resolved Docker endpoint summary in daemon startup state
  • records the last Docker connection error captured at startup
  • exposes those fields through /api/v1/docker/info
  • includes resolved endpoint details in coast doctor connection failures

Important review note

This branch currently includes the resolver base from #61 plus the diagnostics follow-up on top of it.

I’m opening it in the upstream repo now for visibility, but the intended review/merge order is still:

  1. Respect active Docker contexts when resolving the host engine #61
  2. this PR

If #61 lands first, this branch can be rebased down to the diagnostics-only delta.

Scope

  • no transport behavior changes
  • no daemon auto-refresh / re-resolution changes
  • no SSH support work

Validation

  • cargo test -p coast-core test_docker_info_response_serialization
  • COAST_SKIP_UI_BUILD=1 cargo test -p coast-daemon test_docker_info_disconnected_without_docker
  • cargo test -p coast-cli doctor:: -- --nocapture

Refs: #65

Honor Docker's documented precedence by letting DOCKER_CONTEXT override DOCKER_HOST, treating DOCKER_CONTEXT=default as the default local engine selection, and only consulting currentContext when neither env var is set. Keep the shared resolver wiring limited to local/context socket discovery.

Refs: coast-guard#60

Co-authored-by: Codex <noreply@openai.com>
Record the resolved Docker endpoint summary and last connection error in daemon startup state, surface them through the docker info API, and include the resolved endpoint details in coast doctor failures. Keep transport behavior unchanged.

Refs: coast-guard#65

Co-authored-by: Codex <noreply@openai.com>
@agustif agustif force-pushed the af/docker-diagnostics branch from 85b17df to eb7f067 Compare March 12, 2026 12:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant