seahaven-ap/packages/api/src/build-info.ts
Adam Moussa cc637e3732
feat(api): serve portal-shaped health and error envelope
Move liveness to GET /api/health { stage, sha } with a Node 24 image on 8080 so ALB probes and deploy verify do not need auth or a database ping.
2026-09-22 12:33:19 -04:00

9 lines
503 B
TypeScript

// Build-time constant. The API image Dockerfile overwrites the compiled
// `build-info.js` with an inlined GIT_SHA after `tsc`. Keep the exact
// expression `process.env.GIT_SHA` here so local `tsx` still reads the env.
//
// Consumers must prefer BUILD_GIT_SHA over a runtime GIT_SHA env var. A
// deployed task can carry a stale env var from an earlier infra apply while
// its image has since been updated by deploy-api.yaml.
export const BUILD_GIT_SHA: string = process.env.GIT_SHA?.trim() || "";