.claude/skills/ln-774-healthcheck-setup/SKILL.md
Configures health check endpoints for Kubernetes readiness/liveness/startup
npx skillsauth add cbbkrd-tech/jl-finishes ln-774-healthcheck-setupInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Type: L3 Worker Category: 7XX Project Bootstrap Parent: ln-770-crosscutting-setup
Configures health check endpoints for Kubernetes probes and monitoring.
| Aspect | Details | |--------|---------| | Input | Context Store from ln-770 | | Output | Health check endpoints and Kubernetes probe configuration | | Stacks | .NET (AspNetCore.Diagnostics.HealthChecks), Python (FastAPI routes) |
Accept Context Store and scan for dependencies to monitor.
Required Context:
STACK: .NET or PythonPROJECT_ROOT: Project directory pathIdempotency Check:
AddHealthChecks or MapHealthChecks/health route{ "status": "skipped" }Dependency Detection:
| Dependency | .NET Detection | Python Detection |
|------------|----------------|------------------|
| PostgreSQL | Npgsql in csproj | psycopg2 or asyncpg in requirements |
| MySQL | MySql.Data in csproj | mysql-connector-python in requirements |
| Redis | StackExchange.Redis in csproj | redis in requirements |
| RabbitMQ | RabbitMQ.Client in csproj | pika or aio-pika in requirements |
| MongoDB | MongoDB.Driver in csproj | pymongo in requirements |
Define three types of health endpoints per Kubernetes best practices.
| Endpoint | Probe Type | Purpose | Checks |
|----------|------------|---------|--------|
| /health/live | Liveness | Is app alive? | App responds (no dependency checks) |
| /health/ready | Readiness | Can app serve traffic? | All dependencies healthy |
| /health/startup | Startup (K8s 1.16+) | Is app initialized? | Initial warmup complete |
| Probe | Failure Action | Kubernetes Behavior | |-------|----------------|---------------------| | Liveness | Container restart | kubelet restarts container | | Readiness | Remove from service | Traffic stopped, no restart | | Startup | Delay other probes | Liveness/Readiness paused |
Use MCP tools for current documentation.
For .NET:
MCP ref: "ASP.NET Core health checks Kubernetes probes"
Context7: /dotnet/aspnetcore
For Python:
MCP ref: "FastAPI health check endpoint Kubernetes"
Context7: /tiangolo/fastapi
Key Patterns to Research:
Determine probe timing based on application characteristics.
| Parameter | Liveness | Readiness | Startup |
|-----------|----------|-----------|---------|
| initialDelaySeconds | 10 | 5 | 0 |
| periodSeconds | 10 | 5 | 5 |
| timeoutSeconds | 5 | 3 | 3 |
| failureThreshold | 3 | 3 | 30 |
| successThreshold | 1 | 1 | 1 |
Startup Probe Calculation:
Max startup time = initialDelaySeconds + (periodSeconds × failureThreshold)
Default: 0 + (5 × 30) = 150 seconds
| File | Purpose |
|------|---------|
| Extensions/HealthCheckExtensions.cs | Health check registration |
| HealthChecks/StartupHealthCheck.cs | Custom startup check |
Generation Process:
Packages to Add:
AspNetCore.HealthChecks.NpgSql (if PostgreSQL)AspNetCore.HealthChecks.Redis (if Redis)AspNetCore.HealthChecks.MySql (if MySQL)Registration Code:
builder.Services.AddHealthCheckServices(builder.Configuration);
// ...
app.MapHealthCheckEndpoints();
| File | Purpose |
|------|---------|
| routes/health.py | Health check router |
| services/health_checker.py | Dependency health checks |
Generation Process:
Registration Code:
from routes.health import health_router
app.include_router(health_router)
Generate for inclusion in deployment.yaml:
livenessProbe:
httpGet:
path: /health/live
port: 5000
initialDelaySeconds: 10
periodSeconds: 10
timeoutSeconds: 5
failureThreshold: 3
readinessProbe:
httpGet:
path: /health/ready
port: 5000
initialDelaySeconds: 5
periodSeconds: 5
timeoutSeconds: 3
failureThreshold: 3
startupProbe:
httpGet:
path: /health/startup
port: 5000
periodSeconds: 5
failureThreshold: 30
Validation Steps:
Syntax check:
dotnet build --no-restorepython -m py_compile routes/health.pyEndpoint test:
curl http://localhost:5000/health/live
curl http://localhost:5000/health/ready
curl http://localhost:5000/health/startup
Verify response format:
{
"status": "Healthy",
"checks": {
"database": { "status": "Healthy", "duration": "00:00:00.0234" },
"redis": { "status": "Healthy", "duration": "00:00:00.0012" }
},
"totalDuration": "00:00:00.0250"
}
Dependency failure test:
/health/ready returns 503/health/live still returns 200{
"status": "success",
"files_created": [
"Extensions/HealthCheckExtensions.cs",
"HealthChecks/StartupHealthCheck.cs"
],
"packages_added": [
"AspNetCore.HealthChecks.NpgSql"
],
"registration_code": "builder.Services.AddHealthCheckServices(configuration);",
"message": "Configured health checks with liveness, readiness, and startup probes"
}
/health/live, /health/ready, /health/startup per Kubernetes best practicesAddHealthChecks/MapHealthChecks or /health route exists, return status: "skipped"dotnet build or py_compile)Version: 2.0.0 Last Updated: 2026-01-10
testing
When the user wants to plan a content strategy, decide what content to create, or figure out what topics to cover. Also use when the user mentions "content strategy," "what should I write about," "content ideas," "blog strategy," "topic clusters," or "content planning." For writing individual pieces, see copywriting. For SEO-specific audits, see seo-audit.
development
When the user wants to create competitor comparison or alternative pages for SEO and sales enablement. Also use when the user mentions 'alternative page,' 'vs page,' 'competitor comparison,' 'comparison page,' '[Product] vs [Product],' '[Product] alternative,' or 'competitive landing pages.' Covers four formats: singular alternative, plural alternatives, you vs competitor, and competitor vs competitor. Emphasizes deep research, modular content architecture, and varied section types beyond feature tables.
development
Write B2B cold emails and follow-up sequences that get replies. Use when the user wants to write cold outreach emails, prospecting emails, cold email campaigns, sales development emails, or SDR emails. Covers subject lines, opening lines, body copy, CTAs, personalization, and multi-touch follow-up sequences.
development
When the user wants to reduce churn, build cancellation flows, set up save offers, recover failed payments, or implement retention strategies. Also use when the user mentions 'churn,' 'cancel flow,' 'offboarding,' 'save offer,' 'dunning,' 'failed payment recovery,' 'win-back,' 'retention,' 'exit survey,' 'pause subscription,' or 'involuntary churn.' This skill covers voluntary churn (cancel flows, save offers, exit surveys) and involuntary churn (dunning, payment recovery). For post-cancel win-back email sequences, see email-sequence. For in-app upgrade paywalls, see paywall-upgrade-cro.