Sponsor Suno AI Music arrow_forward
Slash Command

Monitoring Setup

Set up monitoring stack with Prometheus, Grafana, alerts

Type
Slash Command
GitHub stars
2.8k
License
MIT
Repo last updated
Sep 27, 2026

What Monitoring Setup is

Monitoring Setup is a slash command published in the jeremylongshore/tons-of-skills-marketplace repository on GitHub, which has about 2.8k stars. The repository describes itself as: “Model-agnostic agent-skills platform with a harness-free canonical layer, verified adapters, and the ccpi package manager. Explore at tonsofskills.com.”

A slash command is a reusable prompt saved as a markdown file and run by typing its name after a slash. In Claude Code, custom commands have been merged into skills: a file in .claude/commands/ and a skill folder in .claude/skills/ both create the same kind of command, and existing command files keep working.

Monitoring Setup gives you a repeatable way to run the same instructions without retyping them, optionally with arguments.

How to install Monitoring Setup

Claude Code

  1. Download monitoring-setup.md from the repository.
  2. Save it to ~/.claude/commands/ (all projects) or .claude/commands/ (one project). As a skill, you can instead save it as ~/.claude/skills/<name>/SKILL.md.
  3. Run it by typing / followed by its name.

Claude Cowork

  1. Turn the command into a skill: create a folder with the file saved as SKILL.md and zip it.
  2. In Customize → Skills, click +, then upload the ZIP.
  3. Run it from any task with / and the skill name.

New to extending Cowork? Our plugins guide and Customize guide explain how skills, plugins, and connectors fit together.

Inside the source file

An excerpt from plugins/packages/devops-automation-pack/plugins/06-deployment/commands/monitoring-setup.md, shared under the repository's MIT license. Read the full file on GitHub.

Generates production-ready monitoring infrastructure with Prometheus, Grafana, and AlertManager including dashboards, alerts, and exporters.

When to Use This

  • Setting up monitoring for new application
  • Need observability for Kubernetes cluster
  • Want pre-configured dashboards and alerts
  • Production deployment requires monitoring
  • Using managed monitoring (CloudWatch, Datadog, etc.)
  • Simple application (overkill for toy projects)

How It Works

You are a monitoring and observability expert. When user runs /monitoring-setup or /ms:

  1. Identify monitoring needs:
  • Infrastructure: Kubernetes, VMs, containers?
  • Applications: Custom metrics needed?
  • Dashboards: What to visualize?
  • Alerts: Critical thresholds?
  1. Generate monitoring stack:
  • Prometheus: Metrics collection and storage
  • Grafana: Visualization dashboards
  • AlertManager: Alert routing and grouping
  • Exporters: Node, kube-state-metrics, application metrics
  1. Create dashboards:
  • System metrics (CPU, memory, disk, network)
  • Application metrics (requests, latency, errors)
  • Custom business metrics
  1. Define alert rules:
  • Critical: Immediate attention (paging)
  • Warning: Requires investigation
  • Info: Awareness only
  1. Provide deployment guide:
  • Installation steps
  • Configuration
  • Testing and validation

Output Format

# Complete monitoring stack configuration
# Prometheus, Grafana, AlertManager
## Deployment

### Install monitoring stack:

[Installation commands]


### Access dashboards:

- Prometheus: http://prometheus:9090
- Grafana: http://grafana:3000 (admin/[password])
- AlertManager: http://alertmanager:9093

Example

User: /ms

Request: Set up monitoring for Kubernetes cluster with Node.js API

Output:

# prometheus-stack.yaml
# Complete monitoring stack for Kubernetes

---
# Namespace
apiVersion: v1
kind: Namespace
metadata:
  name: monitoring

---
# Prometheus ConfigMap
apiVersion: v1
kind: ConfigMap
metadata:
  name: prometheus-config
  namespace: monitoring
data:
…

Deployment Instructions:

# 1. Apply monitoring stack
kubectl apply -f prometheus-stack.yaml

# 2. Verify deployments
kubectl get pods -n monitoring
# Should show prometheus, grafana, alertmanager pods running

# 3. Port-forward to access dashboards locally
kubectl port-forward -n monitoring svc/prometheus 9090:9090 &
kubectl port-forward -n monitoring svc/grafana 3000:3000 &
kubectl port-forward -n monitoring svc/alertmanager 9093:9093 &

# 4. Access dashboards
# Prometheus: http://localhost:9090
# Grafana: http://localhost:3000 (admin/admin)
# AlertManager: http://localhost:9093

# 5. Configure Grafana data source
…

Application Instrumentation (Node.js):

// app.js - Add Prometheus metrics to your Node.js API

const express = require('express');
const promClient = require('prom-client');

const app = express();

// Create metrics registry
const register = new promClient.Registry();

// Default metrics (CPU, memory, etc.)
promClient.collectDefaultMetrics({ register });

// Custom HTTP metrics
const httpRequestDuration = new promClient.Histogram({
  name: 'http_request_duration_seconds',
  help: 'Duration of HTTP requests in seconds',
  labelNames: ['method', 'route', 'status_code'],
…

Kubernetes Pod Annotation (for auto-discovery):

apiVersion: apps/v1
kind: Deployment
metadata:
  name: nodejs-api
spec:
  template:
    metadata:
      annotations:
        prometheus.io/scrape: "true"   # Enable Prometheus scraping
        prometheus.io/port: "3000"     # Metrics port
        prometheus.io/path: "/metrics" # Metrics endpoint
    spec:
      containers:
      - name: api
        image: myregistry/nodejs-api:latest
        ports:
        - containerPort: 3000

Key Metrics to Monitor

Infrastructure:

  • CPU usage (per node, per pod)
  • Memory usage (per node, per pod)
  • Disk space (per node)
  • Network I/O (per node)
  • Pod restarts

Application:

  • HTTP request rate
  • HTTP request duration (p50, p95, p99)
  • HTTP error rate (4xx, 5xx)
  • Active connections
  • Queue depth (if using queues)

Business:

  • Orders per minute
  • Revenue per hour
  • User signups
  • Active sessions

Pro Tips

Use Helm chart for easier deployment: helm install prometheus prometheus-community/kube-prometheus-stack Set up persistent volumes for Prometheus and Grafana (don't lose metrics!) Configure retention period based on storage (default: 15 days) Use Alertmanager routes for critical vs warning alerts Import community dashboards from https://grafana.com/dashboards

Alert Configuration Best Practices

Critical Alerts (Page oncall):

  • Pod/service down
  • Error rate >5%
  • Disk space <10%
  • Memory usage >95%

Warning Alerts (Slack/email):

  • High latency (p95 >1s)

Before you install

  • Read the whole file first. Skills, commands, and subagents are instructions Claude will follow, so make sure they match what you want.
  • Check which tools, scripts, or MCP servers it uses. Local servers and scripts run with your permissions.
  • Try it in a test project or a copy of your files before pointing it at real work.
  • Pin the version you tested, and review changes before updating.
  • Watch for instructions that fetch web content or run shell commands; those are where prompt injection risks start. See our prompt injection guide.

FAQ

What is Monitoring Setup?

Monitoring Setup is a slash command for Claude Code and Claude Cowork from the jeremylongshore/tons-of-skills-marketplace repository on GitHub. Set up monitoring stack with Prometheus, Grafana, alerts

How do I install Monitoring Setup in Claude Code?

Download monitoring-setup.md from the repository. Save it to ~/.claude/commands/ (all projects) or .claude/commands/ (one project). As a skill, you can instead save it as ~/.claude/skills/<name>/SKILL.md. Run it by typing / followed by its name.

Can I use Monitoring Setup in Claude Cowork?

Turn the command into a skill: create a folder with the file saved as SKILL.md and zip it. In Customize → Skills, click +, then upload the ZIP. Run it from any task with / and the skill name.

Is Monitoring Setup safe to install?

It is a third-party community resource, not reviewed by Anthropic or this site. Read the source file first, check which tools and connectors it uses, and install only from sources you trust.

Similar resources

Browse all skills, subagents, and plugins →

Listing data comes from the public GitHub repository and was last checked in September 2026. Excerpts are © their authors and shared under MIT. This directory is independent and not affiliated with Anthropic or the resource's authors.