feat: JSON access log in the platform logging contract
All checks were successful
/ checks (push) Successful in 38s
/ deploy (push) Successful in 4s

This commit is contained in:
nholtware 2026-11-05 10:54:12 -06:00
parent fc7ebd5798
commit 444044b99a
5 changed files with 46 additions and 1 deletions

View file

@ -34,6 +34,13 @@ Everything in `config.js` is public. Never put secrets there.
- nginx listens on 8080: `/healthz` returns 200, unknown paths fall back to
`index.html`, `/assets/*` are cached as immutable, and `index.html` and
`config.js` are not cached.
- Access log: one JSON line per request in the platform logging contract
(`level`, `time`, `service` = `APP_NAME`, `version` = `GIT_SHA`, `req.id`
(echoes `X-Request-Id`), `req.method`, `req.url`, `res.statusCode`,
`responseTime` in ms, `msg: "request completed"`), the same shape as the backend
template. In Kibana (http://kibana.192.168.1.83.nip.io, data view `kube-*`):
`service:"hello-web" and res.statusCode >= 400`. `/healthz` isn't logged.
nginx's own startup/error lines stay plain text (field `log`).
## Deploy