mcpField
I
infrastructure-monitoring

infrastructure-monitoring

github.com/aj-geddes云与 DevOps373465 次安装34 周前更新
代码仓库

关于 infrastructure-monitoring

infrastructure-monitoring 是用于跟踪基础设施健康状况、性能和资源使用情况的技能。它提供 Prometheus、Alertmanager 和 Grafana 参考指南,支持监控部署、告警与分析。

主要功能

  1. 01Prometheus 配置指南
  2. 02告警规则与 Alertmanager 设置
  3. 03Grafana 仪表板参考
  4. 04监控部署指南

适用场景

  1. 01发现事件并发送告警
  2. 02分析资源使用情况
  3. 03查看历史性能趋势

安装

复制下面的命令,在终端中运行。

$npx skills add https://github.com/aj-geddes/useful-ai-prompts --skill infrastructure-monitoring

安装后在 Claude Code 中输入/infrastructure-monitoring确认已加载。

包含的文件

除 SKILL.md 外,安装时一起下载的参考资料和脚本。

references/
alert-rules.md
alertmanager-configuration.md
grafana-dashboard.md
monitoring-deployment.md
prometheus-configuration.md
scripts/
health-check.sh
templates/
dashboard-config.yaml

详细介绍

基础设施监控

目录

概述

实施全面的基础设施监控,以跟踪整个技术栈的系统运行状况、性能指标和资源利用率,并提供告警和可视化功能。

适用场景

  • 实时性能监控
  • 容量规划与趋势分析
  • 事件检测与告警
  • 服务运行状况跟踪
  • 资源利用率分析
  • 性能故障排查
  • 合规性与审计记录
  • 历史数据分析

快速入门

最小可运行示例:

# prometheus.yml
global:
  scrape_interval: 15s
  evaluation_interval: 15s
  external_labels:
    monitor: "infrastructure-monitor"
    environment: "production"

# Alertmanager configuration
alerting:
  alertmanagers:
    - static_configs:
        - targets:
            - localhost:9093

# Rule files
rule_files:
  - "alerts.yml"
  - "rules.yml"

scrape_configs:
  # Prometheus itself
  - job_name: "prometheus"
    static_configs:
      - targets: ["localhost:9090"]
// ... (see reference guides for full implementation)

参考指南

references/ 目录中的详细实现:

指南内容
Prometheus 配置Prometheus 配置
告警规则告警规则
Alertmanager 配置Alertmanager 配置
Grafana 仪表板Grafana 仪表板
监控部署监控部署

最佳实践

✅ 应该
  • 遵循既定的模式和规范
  • 编写整洁且易于维护的代码
  • 添加适当的文档
  • 部署前进行充分测试
❌ 不应该
  • 跳过测试或验证
  • 忽视错误处理
  • 将配置值硬编码

评论

支持 Markdown