Schedule icon
Request icon
Switch icon
Log icon
SlackIncomingWebhook icon

Gatus Automated Endpoint Health and Outage Sentinel

Audit Gatus automated service health endpoints, detect microservice failures or latency spikes, and dispatch automated Slack incident alerts with Kestra.

Categories
Infrastructure

Continuously monitors Gatus automated service health dashboards, audits endpoint availability and error rates across critical microservices, and dispatches actionable Slack incident alerts upon service failure or health check degradation.

How it works

  1. A recurrent Schedule trigger initiates the sentinel audit workflow hourly (disabled initially for on-demand configuration).
  2. The probe_gatus_health task queries /healthz on the Gatus instance to verify dashboard and monitoring controller readiness.
  3. The probe_endpoint_statuses task calls /api/v1/endpoints/statuses to retrieve real-time health evaluations, response times, and failure records across configured services.
  4. The evaluate_service_health task uses Pebble conditionals inside a Switch task to classify health into COMPLIANT, ENGINE_UNREACHABLE, STATUS_API_ERROR, or NO_ENDPOINTS_CONFIGURED.
  5. When failures or outages are detected, contextual Slack notifications are posted via io.kestra.plugin.slack.notifications.SlackIncomingWebhook with diagnostic details, and an audit trail is preserved in Kestra's execution history.

What you get

  • Automated operational surveillance over Gatus automated service health monitoring engines.
  • Proactive alerts when endpoint health checks fail or response latencies degrade across microservices.
  • Contextual incident routing to dedicated SRE and platform engineering Slack channels.
  • Automated deployment gate capability to verify service health before proceeding with CD rollouts.
  • Revision-controlled, searchable execution history providing an immutable operational audit log.

Who it's for

  • Platform Engineers and SREs maintaining automated service health dashboards and status pages.
  • DevOps Teams operating automated deployment pipelines requiring service availability verification.
  • System Administrators governing microservice uptime and endpoint health evaluations.

Why orchestrate this with Kestra

  • Declarative Service Governance: Define endpoint monitoring cadences, target groups, and notification channels in revision-controlled YAML blueprints.
  • Native Secret Isolation: Inject Slack incoming webhook credentials securely using Kestra namespace secrets via {{ secret(...) }} without plaintext exposure.
  • Multi-Branch Flow Routing: Isolate dashboard engine outages from API query errors using native Switch tasks.
  • Auditable Execution Telemetry: Maintain complete execution logs and HTTP diagnostic status codes across every audit run.

Prerequisites

  • A running Gatus service health monitoring instance (accessible over HTTP) with REST API enabled (default port 8080).
  • Network reachability from the Kestra worker or runner environment to the Gatus HTTP endpoint.
  • A Slack Incoming Webhook URL configured with permission to post into your target operations channel.

Secrets

  • SLACK_WEBHOOK_URL: Slack Incoming Webhook URL used for routing operational alerts and incidents.

Quick start

  1. Configure the SLACK_WEBHOOK_URL secret in your Kestra namespace settings.
  2. Import this blueprint into your Kestra instance (e.g., under namespace company.platform).
  3. Click Execute with default parameters or supply your custom gatus_url and target_service_group.
  4. Verify that execution logs display successful HTTP 200 response codes under the Executions tab.
  5. Activate the scheduled_sentinel_audit trigger to establish recurrent automated service health monitoring.

How to extend

  • Automated Deployment Gate: Chain this flow as a pre-flight deployment gate in CI/CD pipelines to block Canary rollouts whenever critical endpoints fail.
  • PagerDuty Escalation: Route ENGINE_UNREACHABLE events directly to on-call schedules in PagerDuty or Opsgenie.
  • Automated Pod Restart: Trigger a Kubernetes pod restart workflow when specific microservice endpoints report persistent connection failures.
  • Multi-Instance Aggregation: Wrap the endpoint status probe inside a Loop task to evaluate Gatus instances across staging, canary, and production environments.

Links

See How

New to Kestra?

Use blueprints to kickstart your first workflows.