Schedule icon
Request icon
Switch icon
SlackIncomingWebhook icon
If icon
Log icon

Gotify Push Notification Gateway Health and Delivery Sentinel

Audit Gotify push notification gateway health, monitor registered application token validity, and alert via Slack to prevent mobile alert delivery failures.

Categories
Infrastructure

Gotify is an open-source, self-hosted push notification and message routing server written in Go with embedded SQLite storage, WebSocket real-time feeds, and a lightweight REST API. Widely adopted across DevOps teams, on-call engineering rotations, and private cloud infrastructure, Gotify provides an independent push notification backbone that eliminates reliance on commercial cloud push services. However, in production telemetry and alert aggregation pipelines, unhandled SQLite database locks, expired client application tokens, or container network partitions can cause push alerts to drop silently, leaving on-call engineers unaware of upstream incidents. This blueprint deploys an automated operational sentinel that polls Gotify core health endpoints, audits registered client applications, routes structured alerts to Slack, and maintains execution audit lineage.

How it works

  1. periodic_gotify_audit (io.kestra.plugin.core.trigger.Schedule) initiates scheduled monitoring every 15 minutes. Shipped disabled so initial connectivity can be verified manually.
  2. probe_gateway_health (io.kestra.plugin.core.http.Request) invokes GET /health to confirm Go runtime health and internal SQLite database read/write responsiveness.
  3. probe_gateway_version (io.kestra.plugin.core.http.Request) invokes GET /version to inspect daemon version metadata and verify REST engine stability.
  4. probe_application_catalog (io.kestra.plugin.core.http.Request) invokes GET /application using an administrative token to audit registered push notification clients.
  5. classify_gateway_status (io.kestra.plugin.core.flow.Switch) evaluates probe results:
    • GATEWAY_UNHEALTHY: Fires if /health returns non-200 or health status is not green, dispatching a high-priority incident alert via io.kestra.plugin.slack.notifications.SlackIncomingWebhook.
    • EMPTY_APPLICATION_CATALOG: Fires when registered client applications drop to zero, warning administrators of potential credential or migration loss.
    • HEALTHY: Confirms that both daemon runtime and message queues operate nominally.
  6. log_sentinel_audit_summary (io.kestra.plugin.core.log.Log) records an immutable execution record documenting evaluated status codes and execution lineage.
  7. Global errors handler catches network connection drops, timeouts, or container crashes, firing an emergency alert to Slack.

What you get

  • Automated continuous surveillance of Gotify push notification gateway daemon availability and database health.
  • Proactive alerts on Slack before notification delivery failures prevent on-call incident notifications from reaching mobile clients.
  • Safe dry-run guarding: default dry_run: true prevents automated mutations during cluster audits.
  • Centralized audit lineage within Kestra tracking notification gateway health history over time.

Who it's for

  • Platform Engineers and SREs hosting internal Gotify alert routing infrastructure on Kubernetes or Docker.
  • DevOps Teams operating self-hosted push notification gateways for alert forwarding and CI/CD pipelines.
  • Incident Response Teams seeking automated health verification for on-call notification channels.

Why orchestrate this with Kestra

Gotify provides high-performance push routing but lacks built-in alerting, cron scheduling, and multi-channel incident escalation. Relying on custom shell scripts or ad-hoc cron jobs introduces maintenance overhead, hard-coded credentials, and zero execution visibility. Kestra provides a declarative YAML blueprint featuring scheduled triggers, masked secret management, conditional branching, and comprehensive execution observability.

Prerequisites

  • A running Gotify server instance (version 2.0+) accessible over HTTP. Gotify provides an official open-source Docker image (gotify/server:latest) requiring zero commercial licensing.
  • An incoming Slack webhook URL for operational notifications.

Secrets

  • SLACK_WEBHOOK_URL: Slack incoming webhook URL for operational notifications and incident routing.
  • GOTIFY_CLIENT_TOKEN: Administrative client token with permissions to query Gotify registered applications.

Quick start

  1. Start a local Gotify test container:
    docker run -d --name gotify-test -p 8080:80 -e GOTIFY_DEFAULTUSER_PASS=admin gotify/server:latest
    
  2. Log in at http://localhost:8080 (admin/admin), navigate to Clients, and generate an administrative client token.
  3. Configure SLACK_WEBHOOK_URL and GOTIFY_CLIENT_TOKEN in your Kestra namespace secrets.
  4. Import this blueprint and execute with default inputs (dry_run: true).
  5. Confirm that log_healthy_state records a successful health check response (health: green).
  6. Test alerting by stopping the container (docker stop gotify-test) and re-running the flow to verify alert_gotify_network_failure.
  7. Enable periodic_gotify_audit to activate recurring 15-minute surveillance.

How to extend

  • Add synthetic message delivery probes using POST /message to test end-to-end client push latency.
  • Integrate with PagerDuty via io.kestra.plugin.pagerduty.notifications.PagerDutyAlert for high-severity push infrastructure outages.
  • Add automated SQLite database backup sync to AWS S3 using io.kestra.plugin.aws.s3.Upload.

Links

See How

New to Kestra?

Use blueprints to kickstart your first workflows.