Problem
docker compose pull can cache a corrupt image layer, resulting in a 0-byte dist/server/server.js. Node.js exits silently with code 0, supervisord retries until FATAL, and the container appears to crash-loop with no actionable error message. The root cause (corrupt/incomplete pull) is not surfaced to the user.
Observed in the wild on 2026-06-18 — docker rmi + fresh pull resolved it.
Proposed Fix: Entrypoint Integrity Check
Before handing off to supervisord, the container entrypoint should verify that dist/server/server.js exists and is non-zero in size. If the check fails, emit a clear human-readable error and exit non-zero so the failure is immediately visible in docker compose logs.
Example shell check to add to entrypoint:
if [ ! -s /app/dist/server/server.js ]; then
echo "❌ FATAL: /app/dist/server/server.js is missing or empty — image may be corrupt."
echo " Fix: docker rmi ghcr.io/yeraze/meshmonitor && docker compose pull && docker compose up -d"
exit 1
fi
Why This Over Other Options
- SHA digest pinning — rejects corrupt pulls at the cost of manual digest updates every release.
- Compose healthcheck — surfaces failure faster via
docker compose ps but doesn't explain why.
- Entrypoint check (recommended) — lowest friction, actionable error message, zero ongoing maintenance cost.
Steps to Reproduce
- Run
docker compose pull while network is unstable or image layer is partially cached.
- Start the stack — meshmonitor exits immediately with code 0, supervisord enters FATAL.
docker compose logs meshmonitor shows no error beyond "exited: meshmonitor (exit status 0; not expected)".
Authored by NodeZero 0️⃣
Problem
docker compose pullcan cache a corrupt image layer, resulting in a 0-bytedist/server/server.js. Node.js exits silently with code 0, supervisord retries until FATAL, and the container appears to crash-loop with no actionable error message. The root cause (corrupt/incomplete pull) is not surfaced to the user.Observed in the wild on 2026-06-18 —
docker rmi+ fresh pull resolved it.Proposed Fix: Entrypoint Integrity Check
Before handing off to supervisord, the container entrypoint should verify that
dist/server/server.jsexists and is non-zero in size. If the check fails, emit a clear human-readable error and exit non-zero so the failure is immediately visible indocker compose logs.Example shell check to add to entrypoint:
Why This Over Other Options
docker compose psbut doesn't explain why.Steps to Reproduce
docker compose pullwhile network is unstable or image layer is partially cached.docker compose logs meshmonitorshows no error beyond "exited: meshmonitor (exit status 0; not expected)".Authored by NodeZero 0️⃣