Warn at boot when the docker deploy provider has no daemon - #897
Merged
Conversation
DEPLOY_PROVIDER defaults to docker when unset, and the docker provider does not touch docker until the first publish, so a core with no reachable daemon looks healthy until a publish fails with a bare socket error. Probe the daemon once at startup, off the boot path, and warn with the reason and the knob to change. Co-Authored-By: QM <qm@ycombinator.com>
Probing from buildApp spawned a real docker subprocess in every test that builds the app, so the check reached far beyond the process it was meant to diagnose. Run it once where a long-lived server starts instead, report a hung daemon as a timeout rather than a bare exit code, and describe the selected provider without asserting how it was selected. Co-Authored-By: QM <qm@ycombinator.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Warn once at core startup when the deploy provider is docker but no Docker daemon is reachable, instead of surfacing a bare socket error at the first publish. The probe runs off the boot path and never blocks startup.
npx tsx --test test/docker-deploy-provider.test.ts(9/9), adjacent deploy tests passnpm run typecheck, eslint, prettier cleanNeed help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.