mirror of
https://github.com/juherr/kill-the-news.git
synced 2026-06-20 22:03:48 +00:00
feat(admin): display running version in footer and /health
Inline package.json version at bundle time via src/config/version.ts (resolveJsonModule), surface it in the shared admin/status footer and add it to the /health JSON so self-hosters can tell which build runs. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
+4
-1
@@ -13,6 +13,7 @@ import { hubRouter } from "./routes/hub";
|
||||
import { apiApp } from "./routes/api";
|
||||
import { handleCloudflareEmail } from "./infrastructure/cloudflare-email";
|
||||
import { Env } from "./types";
|
||||
import { APP_VERSION } from "./config/version";
|
||||
import { logger } from "./infrastructure/logger";
|
||||
import { FeedRepository } from "./infrastructure/feed-repository";
|
||||
import { purgeExpiredFeeds } from "./application/feed-cleanup";
|
||||
@@ -185,7 +186,9 @@ app.get("/favicon.ico", handleFavicon); // readers/browsers that hardcode .ico
|
||||
app.get("/favicon/:feedId", handleFeedFavicon);
|
||||
|
||||
// Health check endpoint for monitoring
|
||||
app.get("/health", (c) => c.json({ status: "ok", timestamp: Date.now() }));
|
||||
app.get("/health", (c) =>
|
||||
c.json({ status: "ok", version: APP_VERSION, timestamp: Date.now() }),
|
||||
);
|
||||
|
||||
// Public status page (counters + link to admin)
|
||||
app.get("/", handleHome);
|
||||
|
||||
Reference in New Issue
Block a user