Wire up deployment metadata: build commit, number, and server start time; v2.0.30
Publish Container / docker (push) Successful in 14m11s

- Dockerfile: expose BUILD_COMMIT and BUILD_NUMBER env vars from build args
  (was COMMIT_SHA only; server was reading BUILD_COMMIT so it always fell through to null)
- CI: pass github.run_number as BUILD_NUMBER build arg
- state.js: record serverStartedAt at module load so deployedAt always shows
  when the current container instance came up, even without an env var
- admin-content.js: fall back COMMIT_SHA → BUILD_COMMIT for older images,
  use state.serverStartedAt when DEPLOYED_AT env var not set

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
nmemmertandClaude Sonnet 4.6 committed 2026-09-17 16:52:44 -04:00
1 parent 4002f1ee93
commit 65623ce0eb
5 files changed
+9 -4

No files matched your search

+2 -2
View File
@@ -227,9 +227,9 @@ export function register(app) {
app.get('/api/admin-ops/status', requireAdminAuth, (_req, res) => {
res.json({
buildCommit: process.env.BUILD_COMMIT ?? null,
buildCommit: process.env.BUILD_COMMIT ?? process.env.COMMIT_SHA ?? null,
buildNumber: process.env.BUILD_NUMBER ?? null,
deployedAt: process.env.DEPLOYED_AT ?? null,
deployedAt: process.env.DEPLOYED_AT ?? state.serverStartedAt,
cachePurge: state.lastCachePurgeStatus,
deployHook: state.lastDeployHookStatus,
})