Skip to content

Improve: reduce the container boot log to six lines - #23

Merged
SandObserver merged 1 commit into
mainfrom
improve/boot-log-output
Aug 10, 2026
Merged

SandObserver merged 1 commit into
mainfrom
improve/boot-log-output

Conversation

@SandObserver

Copy link
Copy Markdown
Owner

Summary

  • Replace the 47-wide boxed banner with aligned label rows, no box drawing and no arrows.
  • Drop the guessed http://localhost:<PORT> line, which named the internal API port; the banner now states the port the container listens on.
  • Print the version without a v prefix, so a locally built image reads Stackyard dev instead of vdev.
  • Add one logfmt readiness record, msg="server ready" with version, port, widget count and Node version.
  • Demote the widget registry inventory from info to debug; refused manifests keep their existing warn records.
  • Collapse the two TRUST_PROXY warnings into one branch, so a misconfigured install gets a single short sentence instead of two long ones.
  • Set loglevel=warn in supervisord.conf, with a comment recording what that costs and why it is acceptable.
  • Point the event listener's stdout_logfile away from /dev/stdout, keeping the READY/RESULT/OK protocol out of docker logs. stderr_logfile is unchanged, so the fatal message still reaches the operator.
  • Run the entrypoint's config check as nginx -t -q, which prints only on failure.

Boot output on a correctly configured container goes from 23 lines to 6 plus a leading blank. A misconfigured one adds exactly one WRN line.

Testing
All green, including the Docker build and the container's fatal-exit path checked against an unmodified control. Added 13 tests: the banner, the readiness record, the registry level at default and at debug, both TRUST_PROXY branches, the event listener wiring and the quiet config check.

Checklist

  • Stays within the project constraints: one container, no runtime dependencies, no build step (see CONTRIBUTING.md).
  • Tests added or updated for new logic, and the full suite, lint, and typechecks pass.
  • Docs updated if behavior or configuration changed. The documentation change lands separately, so it can describe what actually shipped.
  • CHANGELOG.md updated under Unreleased if the change is user-visible. The changelog entry lands with the documentation change.

Replace the boxed banner with aligned label rows and drop the guessed
http://localhost:<port> URL, which named the internal API port while nginx
serves on 80 and the shipped compose maps 8700:80.

Add one logfmt readiness record, since the banner bypasses both level
filtering and the logfmt shape and left nothing greppable to prove the app
came up.

Demote the widget registry inventory to debug, collapse the two TRUST_PROXY
warnings into a single branch, quiet supervisord to warn, keep the event
listener protocol out of the container log, and silence the entrypoint's
nginx config check on success.
@SandObserver SandObserver added the enhancement New feature or request label Aug 10, 2026
@SandObserver
SandObserver merged commit dea86df into main Aug 10, 2026
4 checks passed
@SandObserver
SandObserver deleted the improve/boot-log-output branch August 10, 2026 21:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant