Add readiness endpoint and clear adminKey in Helm values
This commit is contained in:
@@ -3,6 +3,8 @@ from pydantic import BaseModel
|
||||
import uvicorn
|
||||
from datetime import datetime
|
||||
from fastapi import FastAPI, HTTPException
|
||||
from pydantic import BaseModel
|
||||
from typing import Optional, List
|
||||
import os
|
||||
import httpx
|
||||
|
||||
@@ -60,6 +62,12 @@ async def health():
|
||||
"""Health check endpoint"""
|
||||
return {"status": "healthy", "service": "api", "timestamp": datetime.now().isoformat()}
|
||||
|
||||
# Readiness check
|
||||
@app.get("/ready")
|
||||
async def ready():
|
||||
"""Readiness check endpoint"""
|
||||
return {"status": "ready", "service": "api", "timestamp": datetime.now().isoformat()}
|
||||
|
||||
# Items endpoints
|
||||
@app.get("/items", response_model=List[Item], tags=["Items"])
|
||||
async def get_items():
|
||||
|
||||
Reference in New Issue
Block a user