https://github.com/alexdemure/gadfasthealth
FastAPI health check extension for Kubernetes liveness, readiness, and startup probes
https://github.com/alexdemure/gadfasthealth
fastapi-health
Last synced: 5 days ago
JSON representation
FastAPI health check extension for Kubernetes liveness, readiness, and startup probes
- Host: GitHub
- URL: https://github.com/alexdemure/gadfasthealth
- Owner: AlexDemure
- License: mit
- Created: 2025-04-22T14:59:36.000Z (28 days ago)
- Default Branch: production
- Last Pushed: 2025-04-22T15:08:16.000Z (28 days ago)
- Last Synced: 2025-04-22T15:45:15.343Z (28 days ago)
- Topics: fastapi-health
- Language: Python
- Homepage:
- Size: 0 Bytes
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
FastAPI health check extension for Kubernetes liveness, readiness, and startup probes---
### Installation
```
pip install gadfasthealth
```### Usage
```python
def check_redis() -> bool:
return Falseasync def check_db() -> bool:
return Trueapp = fastapi.FastAPI()
health = Health(
("/-/liveness", check_db),
("/-/readiness", check_db, check_redis),
("/-/startup", check_db),
("/-/custom"),
)app.include_router(health.router)
```