- Add pyproject.toml as single source of truth for version and metadata - Update config.py to read version from pyproject.toml using tomllib - FastAPI app now loads title and version dynamically from config - Health endpoint now includes version in response - Dockerfile updated to include pyproject.toml 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
+4
-2
@@ -102,9 +102,10 @@ async def lifespan(app: FastAPI):
|
||||
|
||||
|
||||
# FastAPI app
|
||||
settings = get_settings()
|
||||
app = FastAPI(
|
||||
title="The Scheduler",
|
||||
version="1.0.0",
|
||||
title=settings.app_name,
|
||||
version=settings.app_version,
|
||||
description="System-wide maintenance orchestration - backups, doc mirroring, cleanup, task automation",
|
||||
lifespan=lifespan
|
||||
)
|
||||
@@ -134,6 +135,7 @@ async def health(
|
||||
"""Health check endpoint."""
|
||||
return {
|
||||
"status": "healthy",
|
||||
"version": settings.app_version,
|
||||
"scheduler_running": sched.running,
|
||||
"jobs_count": len(sched.get_jobs()),
|
||||
"database": settings.postgres_db
|
||||
|
||||
Reference in New Issue
Block a user