Commands icon
If icon
SlackIncomingWebhook icon
Schedule icon

Kubernetes PersistentVolumeClaim Failed Binding and Volume Stalling Sentinel

Audits Kubernetes namespaces to detect unbound or provisioning-failed PersistentVolumeClaims preventing stateful pod scheduling.

Categories
CloudInfrastructure

How it works

This workflow connects to the target Kubernetes cluster and audits all PersistentVolumeClaims across namespaces using the kubectl CLI. It inspects .status.phase and flags any claims that have failed to transition to the Bound status. If the number of unbound claims exceeds the configured threshold, a formatted Slack incident alert is immediately triggered with namespace and volume details.

What you get

  • Cluster-wide visibility into unfulfilled storage claims and provisioning failures.
  • Early warning before developers report stuck deployments or scheduling timeouts.
  • Automated incident notification with exact namespace, PVC name, storage class, and requested capacity.

Who it's for

  • Platform Engineers and Kubernetes Cluster Administrators managing dynamic volume provisioners (CSI drivers).
  • SREs maintaining production stateful workloads such as databases, message queues, and caching layers.

Why orchestrate this with Kestra

  • Native Scheduling: Run regular, automated health audits without maintaining standalone cron runners.
  • Flexible Extensibility: Seamlessly extend the flow to trigger CSI driver pod restarts or automatically open Jira tickets.
  • Centralized Alerting: Integrate directly with Slack, PagerDuty, or Microsoft Teams with zero boilerplate code.

Prerequisites

  • A Kubernetes service account or kubeconfig secret with get and list permissions for persistentvolumeclaims across all namespaces.
  • A Slack Incoming Webhook URL configured as secret SLACK_WEBHOOK.

Quick start

  1. Import this blueprint into your Kestra instance.
  2. Configure the SLACK_WEBHOOK secret.
  3. Run an execution or enable the scheduled trigger to start continuous storage volume auditing.

How to extend

  • Add an automated remediation step using kubectl describe pvc to capture underlying CSI driver error events.
  • Filter alerts by specific business-critical namespaces (e.g., production, databases).

Links

See How

New to Kestra?

Use blueprints to kickstart your first workflows.