Skip to main content

Send real-time Kubernetes(EKS/GKE/AKS) CPU spike alerts from Prometheus to Slack

Workflow preview

Workflow preview
100%
Send real-time Kubernetes(EKS/GKE/AKS) CPU spike alerts from Prometheus to Slack preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

Summary This workflow monitors Kubernetes pod CPU usage using Prometheus, and sends real time Slack alerts when CPU consumption crosses a threshold (e.g., 0.8 cores). It groups pods by applicati...

Best for

  • DevOps automation workflows
  • Multimodal AI automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.scheduletrigger, n8n-nodes-base.httprequest, n8n-nodes-base.code, n8n-nodes-base.if, n8n-nodes-base.stickynote

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by John Pranay Kumar Reddy.

Original n8n.io source

1.1 Workflow description

Title
Send real-time Kubernetes(EKS/GKE/AKS) CPU spike alerts from Prometheus to Slack
Workflow name
Send real-time Kubernetes(EKS/GKE/AKS) CPU spike alerts from Prometheus to Slack

๐Ÿงพ Summary

This workflow monitors Kubernetes pod CPU usage using Prometheus, and sends real-time Slack alerts when CPU consumption crosses a threshold (e.g., 0.8 cores). It groups pods by application name to reduce noise and improve clarity, making it ideal for observability across multi-pod deployments like Argo CD, Loki, Promtail, applications etc.

๐Ÿ‘ฅ Whoโ€™s it for

Designed for DevOps and SRE teams and platform teams, this workflow is 100% no-code, plug-and-play, and can be easily extended to support memory, disk, or network spikes. It eliminates the need for Alertmanager by routing critical alerts directly into Slack using native n8n nodes.

โš™๏ธ What it does

This n8n workflow polls Prometheus every 5 minutes โฑ๏ธ, checks if any pod's CPU usage crosses a defined threshold (e.g., 0.8 cores) ๐Ÿšจ, groups them by app ๐Ÿงฉ, and sends structured alerts to a Slack channel ๐Ÿ’ฌ.

๐Ÿ› ๏ธ How to set up

๐Ÿ”— Set your Prometheus URL with required metrics (container_cpu_usage_seconds_total, kube_pod_container_resource_limits)

๐Ÿ” Add your Slack bot token with chat:write scope

๐Ÿงฉ Import the workflow, customize:

Threshold (e.g., 0.8 cores)

Slack channel

Cron schedule

๐Ÿ“‹ Requirements

  • A working Prometheus stack with kube-state-metrics
  • Slack bot credentials
  • n8n instance (self-hosted or cloud)

๐Ÿง‘โ€๐Ÿ’ป How to customize

๐Ÿง  Adjust threshold values or query interval

๐Ÿ“ˆ Add memory/disk/network usage metrics

๐Ÿ’ก This is a plug-and-play Kubernetes alerting template for real-time observability.

๐Ÿท๏ธ Tags:

Prometheus, Slack, Kubernetes, Alert, n8n, DevOps, Observability, CPU Spike, Monitoring

Prometheus Spike Alert to Slack

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - ๐Ÿ•’ Every 5 Min Trigger

Type / Role
n8n-nodes-base.scheduleTrigger - scheduleTrigger
Config choices
Version 1.2

Block 2 - ๐Ÿ“ค Send Alerts to Slack

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 3 - Format Prometheus JSON

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 4 - Check Number of Pods in Group

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.2

Block 5 - Format Batched Slack Message

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 6 - Format Single Pod Slack Message

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 7 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 8 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 9 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 10 - Sticky Note3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 11 - Query Prometheus for CPU Spikes

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 12 - Sticky Note4

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 13 - Sticky Note5

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 14 - Sticky Note6

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 15 - Sticky Note7

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

3. Summary Table

Workflow Send real-time Kubernetes(EKS/GKE/AKS) CPU spike alerts from Prometheus to Slack
Complexity advanced
Nodes 15
Categories DevOps, Multimodal AI
Author John Pranay Kumar Reddy
Published 07 Aug 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/7145/7145.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Send real-time Kubernetes(EKS/GKE/AKS) CPU spike alerts from Prometheus to Slack do?

Summary This workflow monitors Kubernetes pod CPU usage using Prometheus, and sends real time Slack alerts when CPU consumption crosses a threshold (e.g., 0.8 cores). It groups pods by applicati...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your DevOps, Multimodal AI use case.