원클릭으로
grafana-dashboard-validation
Pre-deployment validation for Grafana dashboards to catch errors before they reach production.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Pre-deployment validation for Grafana dashboards to catch errors before they reach production.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Behavioral testing methodology — test what users experience, not how code is structured. Use when writing tests, reviewing test quality, planning test strategy for new features, or when existing tests are brittle/verbose/coupled to implementation details. Triggers: writing tests, TDD, test review, "tests keep breaking", "too many mocks", "tests are verbose", test coverage planning, behavior-driven development.
Summon 8–12 fictional but statistically plausible people from Kyrgyzstan to judge your web app. They take screenshots, click around, get confused, get delighted, and write honest reviews in Russian. Output: a single .md report with embedded screenshots. Use when you need brutal UX feedback from people who ride marshrutkas.
Artemy Lebedev-style бизнес-линч design review. Opens the site in a real browser, screenshots everything, then tears it apart (or praises it) in his signature voice — brutal, specific, visual. Use when you want a no-bullshit design review, 'линч', 'lebedev review', 'artemy review', or 'roast my site'.
Autonomous experiment loop — modify code, measure, keep/discard, repeat forever. Based on Karpathy's autoresearch pattern. Use when there's working code + a measurable metric to optimize. Agent works while you sleep.
Iterative deep research agent — recursive breadth×depth tree search that accumulates learnings, generates follow-ups, and produces cited reports. Uses exa + serper + subagents. Use when user says 'deep research', 'investigate', 'deep dive', 'thorough analysis', or needs multi-source synthesis with depth.
Detect and fix design system leaks — default shadcn/bootstrap/MUI styling breaking through your brand. Use when: UI feels 'template-y', 'looks like shadcn', 'too generic', buttons are inconsistent colors, cards look default, or after shipping many features fast. Also: 'audit my design', 'check consistency', 'brand leak', 'fix the defaults'.
| name | grafana-dashboard-validation |
| description | Pre-deployment validation for Grafana dashboards to catch errors before they reach production. |
Pre-deployment validation for Grafana dashboards to catch errors before they reach production.
Trigger Patterns:
monitoring/grafana/dashboards/.json files with Grafana panel structureUse Proactively When:
# After any dashboard edit
python scripts/validate_dashboard.py --quick path/to/dashboard.json
# Validate all dashboards against live Prometheus
python scripts/validate_dashboard.py --all
# Single dashboard with full checks
python scripts/validate_dashboard.py path/to/dashboard.json
# Quick validation with JSON output
python scripts/validate_dashboard.py --quick --json --all
# Parse results
python scripts/validate_dashboard.py --quick --json --all | jq '.[] | select(.success==false)'
# Copy from this skill to project
cp ~/.claude/skills/grafana-dashboard-validation/validate_dashboard.py scripts/
# Or download latest version
curl -o scripts/validate_dashboard.py \
https://raw.githubusercontent.com/YOUR_ORG/grafana-tools/main/validate_dashboard.py
#!/bin/bash
# scripts/sync_grafana.sh
# Always validate first
python scripts/validate_dashboard.py --all || {
echo "❌ Validation failed. Fix errors or use --force to override"
exit 1
}
# Then sync
rsync -av monitoring/grafana/ user@server:/path/to/grafana/
# .git/hooks/pre-commit
if git diff --cached --name-only | grep -q "dashboards.*\.json"; then
python scripts/validate_dashboard.py --quick --all || exit 1
fi
Check if validation exists:
# Look for validator
ls -la scripts/validate_dashboard.py 2>/dev/null || echo "No validator found"
# If missing, add it
if [ ! -f scripts/validate_dashboard.py ]; then
echo "📝 Adding dashboard validator to project..."
cp ~/.claude/skills/grafana-dashboard-validation/validate_dashboard.py scripts/
fi
# Check if metric exists
curl -s http://prometheus:9090/api/v1/label/__name__/values | jq '.data[] | select(contains("your_metric"))'
# Common causes:
# 1. Metric not yet created (deploy app first)
# 2. Wrong metric name (check spelling)
# 3. Prometheus not scraping (check targets)
# Test query directly
curl -g 'http://prometheus:9090/api/v1/query?query=your_promql_here'
# Common causes:
# 1. No data in time range (normal for new deploy)
# 2. Wrong label filters
# 3. Missing service
# Validate syntax
promtool check query "your_promql_here"
# Common issues:
# 1. Unbalanced parentheses
# 2. Invalid function names
# 3. Wrong aggregation syntax
Must Fix (Errors):
Should Fix (Warnings):
Informational:
name: Validate Dashboards
on:
pull_request:
paths:
- 'monitoring/grafana/dashboards/**'
jobs:
validate:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- run: pip install requests
- run: python scripts/validate_dashboard.py --quick --json --all
validate-dashboards:
stage: test
script:
- python scripts/validate_dashboard.py --quick --all
only:
changes:
- monitoring/grafana/dashboards/**
# .git/hooks/pre-push
#!/bin/bash
if git diff --name-only origin/main HEAD | grep -q "dashboards.*\.json"; then
echo "Validating dashboards before push..."
python scripts/validate_dashboard.py --all || {
echo "Push blocked: Dashboard validation failed"
exit 1
}
fi
# After editing any dashboard.json
print("I'll validate that dashboard to catch any issues...")
subprocess.run(["python", "scripts/validate_dashboard.py", "--quick", "path/to/dashboard.json"])
# Always run before sync
print("Let me validate all dashboards before deploying...")
result = subprocess.run(["python", "scripts/validate_dashboard.py", "--all"])
if result.returncode != 0:
print("Found issues - let me help fix them...")
# After generating dashboard JSON
with open("new_dashboard.json", "w") as f:
json.dump(dashboard_config, f, indent=2)
# Immediately validate
print("Validating the generated dashboard...")
subprocess.run(["python", "scripts/validate_dashboard.py", "--quick", "new_dashboard.json"])
For large deployments (>50 dashboards), use quick mode in CI and full mode manually.
Required Python packages:
requests (for Prometheus API)json (standard library)pathlib (standard library)argparse (standard library)No external tools required for quick mode.
This skill provides fail-fast feedback for Grafana dashboards:
Always validate before deploying. The 30 seconds spent validating saves hours of debugging broken dashboards in production.