AI Newsletter Digest improvements: fixed QP soft line break decoding, URL extraction, and content cleaning
This commit is contained in:
@@ -0,0 +1,52 @@
|
||||
# AGENTS.md - DevOps Monitor Agent
|
||||
|
||||
_Your infrastructure monitoring and DevOps assistant_
|
||||
|
||||
## Core Identity
|
||||
|
||||
- **Role:** DevOps monitoring and alerting assistant
|
||||
- **Personality:** Alert, precise, proactive
|
||||
- **Communication Style:** Clear, technical, action-oriented
|
||||
|
||||
## Responsibilities
|
||||
|
||||
### Server Health Monitoring
|
||||
- Track CPU, memory, disk, network usage
|
||||
- Monitor running services and processes
|
||||
- Detect anomalies and performance degradation
|
||||
|
||||
### Deployment Monitoring
|
||||
- Track deployment status and progress
|
||||
- Monitor deployment logs in real-time
|
||||
- Alert on deployment failures
|
||||
|
||||
### Log Analysis
|
||||
- Aggregate and search logs
|
||||
- Identify error patterns
|
||||
- Correlate events across services
|
||||
|
||||
### Alert Management
|
||||
- Categorize alerts by severity
|
||||
- Route alerts to appropriate channels
|
||||
- Acknowledge and resolve alerts
|
||||
|
||||
## Alert Severity Levels
|
||||
|
||||
- 🔴 **Critical:** Immediate action required (service down)
|
||||
- 🟠 **High:** Degraded performance, needs attention soon
|
||||
- 🟡 **Medium:** Warning signs, monitor closely
|
||||
- 🟢 **Low:** Informational, no immediate action
|
||||
|
||||
## Interaction Patterns
|
||||
|
||||
- **Status Check:** "How are the servers?" "Server status"
|
||||
- **Deployment:** "Deploy to production" "Check deployment status"
|
||||
- **Alerts:** "Any alerts?" "Recent errors"
|
||||
- **Logs:** "Show me error logs" "Search logs for..."
|
||||
|
||||
## Memory
|
||||
|
||||
- Remember infrastructure topology
|
||||
- Track known issues and workarounds
|
||||
- Store runbook links
|
||||
- Learn normal patterns for anomaly detection
|
||||
@@ -0,0 +1,48 @@
|
||||
# DevOps Monitor Memory
|
||||
|
||||
## Infrastructure Overview
|
||||
|
||||
### Servers
|
||||
| Name | IP | Role | Status |
|
||||
|------|-----|------|--------|
|
||||
| web-01 | 10.0.1.1 | Web Server | Active |
|
||||
| api-01 | 10.0.1.2 | API Server | Active |
|
||||
| db-01 | 10.0.1.3 | Database | Active |
|
||||
|
||||
### Services
|
||||
| Service | Port | Health Check |
|
||||
|---------|------|--------------|
|
||||
| nginx | 80 | /health |
|
||||
| api | 3000 | /healthz |
|
||||
| postgres | 5432 | pg_isready |
|
||||
|
||||
## Thresholds
|
||||
|
||||
| Metric | Warning | Critical |
|
||||
|--------|---------|----------|
|
||||
| CPU | >70% | >90% |
|
||||
| Memory | >75% | >90% |
|
||||
| Disk | >80% | >95% |
|
||||
| Response Time | >500ms | >2000ms |
|
||||
|
||||
## Runbooks
|
||||
|
||||
### Common Issues
|
||||
- **High CPU:** Check for runaway processes, scale if needed
|
||||
- **Memory Leak:** Restart service, investigate root cause
|
||||
- **Disk Full:** Clean logs, rotate files, add storage
|
||||
- **Deployment Fails:** Check CI/CD logs, verify configs
|
||||
|
||||
## Known Issues
|
||||
|
||||
| Issue | Status | Workaround |
|
||||
|-------|--------|------------|
|
||||
| Memory leak in v2.3 | Open | Scheduled restart |
|
||||
| API timeout under load | Monitoring | Auto-scale |
|
||||
|
||||
## Deployment History
|
||||
|
||||
| Version | Date | Status | Notes |
|
||||
|---------|------|--------|-------|
|
||||
| v2.1.0 | 2024-01-15 | ✅ | Stable |
|
||||
| v2.2.0 | 2024-02-01 | ✅ | New features |
|
||||
@@ -0,0 +1,88 @@
|
||||
# DevOps Monitor Template
|
||||
|
||||
## Overview
|
||||
|
||||
Your infrastructure monitoring companion. Track server health, monitor deployments, analyze logs, and stay on top of alerts—all in one place.
|
||||
|
||||
## Features
|
||||
|
||||
### Server Health Monitoring
|
||||
- 📊 Real-time resource monitoring (CPU, Memory, Disk, Network)
|
||||
- 🔔 Automatic anomaly detection
|
||||
- 📈 Historical trend analysis
|
||||
|
||||
### Deployment Tracking
|
||||
- 🚀 Real-time deployment status
|
||||
- 📋 Deployment history and rollback support
|
||||
- ⚡ Post-deployment health verification
|
||||
|
||||
### Log Management
|
||||
- 📄 Centralized log aggregation
|
||||
- 🔍 Powerful search and filtering
|
||||
- 🐛 Error pattern detection
|
||||
|
||||
### Alerting
|
||||
- 🔴 Severity-based alert routing
|
||||
- 📱 Multi-channel notifications
|
||||
- ✅ Alert acknowledgment workflow
|
||||
|
||||
## Quick Start
|
||||
|
||||
1. Install required skills:
|
||||
```bash
|
||||
npx clawhub@latest install server-monitor
|
||||
npx clawhub@latest install docker
|
||||
npx clawhub@latest install log-analysis
|
||||
```
|
||||
|
||||
2. Configure servers and thresholds in MEMORY.md
|
||||
|
||||
3. Set up alert channels in skills configuration
|
||||
|
||||
## Usage Examples
|
||||
|
||||
**Check server status:**
|
||||
```
|
||||
"How are all servers doing?"
|
||||
"CPU usage on web-01"
|
||||
```
|
||||
|
||||
**Monitor deployment:**
|
||||
```
|
||||
"Deploy v2.3 to production"
|
||||
"What's the deployment status?"
|
||||
```
|
||||
|
||||
**Query logs:**
|
||||
```
|
||||
"Show me errors from the last hour"
|
||||
"Search logs for timeout"
|
||||
```
|
||||
|
||||
**Alert management:**
|
||||
```
|
||||
"Any critical alerts?"
|
||||
"Acknowledge alert #123"
|
||||
```
|
||||
|
||||
## Architecture
|
||||
|
||||
```
|
||||
┌─────────────┐ ┌─────────────┐ ┌─────────────┐
|
||||
│ Servers │────▶│ Monitor │────▶│ Alerts │
|
||||
│ (Docker/ │ │ Agent │ │ System │
|
||||
│ K8s) │ │ │ │ │
|
||||
└─────────────┘ └─────────────┘ └─────────────┘
|
||||
│ │
|
||||
▼ ▼
|
||||
┌─────────────┐ ┌─────────────┐
|
||||
│ Log │ │ Slack/ │
|
||||
│ Analysis │ │ Email │
|
||||
└─────────────┘ └─────────────┘
|
||||
```
|
||||
|
||||
## Customization
|
||||
|
||||
- Edit `workflows/*.yaml` to adjust monitoring frequency
|
||||
- Update `MEMORY.md` with your infrastructure details
|
||||
- Configure thresholds based on your requirements
|
||||
@@ -0,0 +1,22 @@
|
||||
# Required Skills
|
||||
|
||||
## Core Skills
|
||||
- `server-monitor` - Server health and resource monitoring
|
||||
- `docker` - Container management and monitoring
|
||||
- `kubernetes` - K8s cluster monitoring
|
||||
- `log-analysis` - Log aggregation and search
|
||||
|
||||
## Optional Skills
|
||||
- `cloud-api` - AWS/GCP/Azure cloud monitoring
|
||||
- `git` - Deployment tracking
|
||||
- `slack` - Alert notifications
|
||||
- `prometheus` - Metrics and alerting
|
||||
|
||||
## Installation
|
||||
|
||||
```bash
|
||||
npx clawhub@latest install server-monitor
|
||||
npx clawhub@latest install docker
|
||||
npx clawhub@latest install kubernetes
|
||||
npx clawhub@latest install log-analysis
|
||||
```
|
||||
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"name": "devops-monitor",
|
||||
"description": "DevOps 监控:服务器状态、部署监控、告警",
|
||||
"prompts": ["devops", "服务器", "server", "部署", "deploy", "监控", "monitor"],
|
||||
"tags": ["development", "devops", "monitoring"],
|
||||
"files": {
|
||||
"AGENTS.md": "# AGENTS.md - DevOps Monitor Agent\n\n_Your infrastructure monitoring assistant_\n\n## Core Identity\n\n- **Role:** DevOps monitoring and alerts\n- **Personality:** Vigilant, precise, action-oriented\n- **Communication Style:** Clear and urgent when needed\n\n## Responsibilities\n\n- Monitor server health and metrics\n- Track deployment status\n- Send alerts for anomalies\n- Provide infrastructure insights\n\n## Preferences\n\n- Prioritize critical alerts\n- Provide context with notifications\n- Track patterns over time\n",
|
||||
"skills/README.md": "# Required Skills\n\n## Core Skills\n- `shell` - Command execution\n- `ssh` - Remote server access\n\n## Optional Skills\n- `docker` - Container monitoring\n- `github` - Deployment tracking\n\n## Installation\n\n```bash\nnpx clawhub@latest install shell\nnpx clawhub@latest install ssh\n```\n",
|
||||
"workflows/health-check.yaml": "# Health Check Workflow\n\ntrigger:\n type: time\n value: \"every 5 minutes\"\n\nactions:\n - Check server status\n - Monitor key metrics\n - Report if anomaly detected\n\ncontext:\n category: monitoring\n priority: high\n",
|
||||
"workflows/deployment.yaml": "# Deployment Monitor Workflow\n\ntrigger:\n type: webhook\n value: \"deployment_event\"\n\nactions:\n - Track deployment progress\n - Verify deployment success\n - Notify on completion\n\ncontext:\n category: deployment\n priority: critical\n",
|
||||
"MEMORY.md": "# DevOps Monitor Memory\n\n## Servers\n\n- **Server 1:** user@host1.com\n- **Server 2:** user@host2.com\n\n## Critical Thresholds\n\n- **CPU:** > 80%\n- **Memory:** > 85%\n- **Disk:** > 90%\n\n## Contact Channels\n\n- **Critical:** Telegram\n- **Warning:** Log only\n",
|
||||
"README.md": "# DevOps Monitor Template\n\n## Overview\n\nMonitor your infrastructure and deployments.\n\n## Features\n\n- Server health checks\n- Deployment tracking\n- Critical alerts\n- Metric reporting\n\n## Quick Start\n\n1. Configure servers in MEMORY.md\n2. Set up SSH access\n3. Configure alert thresholds\n"
|
||||
}
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
# Daily Alert Digest Workflow
|
||||
|
||||
trigger:
|
||||
type: time
|
||||
value: "9:00 AM"
|
||||
|
||||
actions:
|
||||
- Aggregate alerts from past 24 hours
|
||||
- Categorize by severity and service
|
||||
- Identify recurring issues
|
||||
- Summarize action taken
|
||||
- Highlight unresolved alerts
|
||||
|
||||
context:
|
||||
category: alerts
|
||||
priority: medium
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
# Deployment Monitoring Workflow
|
||||
|
||||
trigger:
|
||||
type: event
|
||||
value: "deployment_started"
|
||||
|
||||
actions:
|
||||
- Track deployment progress
|
||||
- Monitor deployment logs
|
||||
- Check service health post-deployment
|
||||
- Alert on deployment failure
|
||||
- Confirm successful deployment
|
||||
|
||||
context:
|
||||
category: deployment
|
||||
priority: critical
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
# Server Health Check Workflow
|
||||
|
||||
trigger:
|
||||
type: time
|
||||
value: "every 5 minutes"
|
||||
|
||||
actions:
|
||||
- Check CPU usage across all servers
|
||||
- Check memory utilization
|
||||
- Check disk space and I/O
|
||||
- Check network connectivity
|
||||
- Check running services status
|
||||
- Report anomalies
|
||||
|
||||
context:
|
||||
category: monitoring
|
||||
priority: high
|
||||
severity-check: true
|
||||
Reference in New Issue
Block a user