Conversation
…IRED trim) Addresses the second steelman review of the #298 hardening. entrypoint.sh: - Extend nginx drain budget from 2s (10 x 0.2s) to 10s (10 x 1s) so legitimate in-flight requests (SSE, slow clients) finish before tini SIGKILLs nginx. Matches nginx's own graceful-stop SLA. - Log a WARNING when nginx doesn't drain within the budget so operators see timed-out shutdowns instead of silently truncated requests. - Integer-only `sleep` in the poll loop so the script is portable to BusyBox-coreutils bases if the runtime image ever migrates off Debian. - Trim whitespace around SSL_REQUIRED before the case match so values like " true " (common paste-from-.env mistake) no longer hard-fail. docker-validate.yml: - Add `workflow_dispatch` trigger so flaky transient failures can be re-run without pushing an empty commit. - Switch to `load: true` and add smoke test steps for both matrix rows: * Dockerfile: `nginx -t` catches default-config syntax regressions. * Dockerfile.ssl: verify tini + sphere-entrypoint + curl + nginx are present and the entrypoint script is syntactically valid bash. Catches entrypoint-path typos and shebang regressions that would otherwise only surface at deploy time. Verified locally: - docker build -f Dockerfile.ssl succeeds. - SSL_REQUIRED=" true " now starts cleanly (was: exit 1). - SSL_REQUIRED="bogus" still exits 1 with a clear error. - docker stop --time=15 still produces exit code 143. - Smoke command used in CI works against the locally-built image.
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.
Summary
Second pass of the steelman review on the hardening landed via #298. All findings from that review that could be addressed with code are addressed here. Branch protection on `main` is the only outstanding item and needs a GitHub Settings UI click, not code.
entrypoint.sh
docker-validate.yml
Test plan (ran locally)
Outstanding (non-code)