vuralserhat86

deploy_monitoring

27
10
# Install this skill:
npx skills add vuralserhat86/antigravity-agentic-skills --skill "deploy_monitoring"

Install specific skill from multi-skill repository

# Description

Health checks, metrics, alerting ve rollback stratejileri.

# SKILL.md


name: deploy_monitoring
router_kit: DevOpsKit
description: Health checks, metrics, alerting ve rollback stratejileri.
metadata:
skillport:
category: operations
tags: [automation, aws, bash scripting, ci/cd, cloud computing, containerization, deploy monitoring, deployment strategies, devops, docker, gitops, infrastructure, infrastructure as code, kubernetes, linux, logging, microservices, monitoring, orchestration, pipelines, reliability, scalability, security, server management, terraform] - deploy-cicd


📊 Deploy Monitoring

Monitoring, alerting ve rollback stratejileri.


❤️ Health Checks

app.get('/health', (req, res) => {
  res.json({ status: 'healthy', version: process.env.APP_VERSION });
});

app.get('/ready', async (req, res) => {
  await db.$queryRaw`SELECT 1`;
  res.json({ status: 'ready' });
});

📈 Metrics (Prometheus)

const httpDuration = new Histogram({
  name: 'http_request_duration_seconds',
  help: 'Duration of HTTP requests',
  labelNames: ['method', 'route', 'status'],
});

🚨 Alert Rules

- alert: HighErrorRate
  expr: rate(http_requests_total{status=~"5.."}[5m]) > 0.05
  for: 5m
  labels:
    severity: critical

⏪ Rollback

# Kubernetes
kubectl rollout undo deployment/app

# Vercel
vercel rollback

🔄 Workflow

Kaynak: Google SRE Book - Monitoring & Prometheus Best Practices

Aşama 1: Observability Instrumentation

  • [ ] Health Checks: /health (Liveness) ve /ready (Readiness) uç noktalarını tanımla.
  • [ ] Custom Metrics: Uygulamaya özel kritik metrikleri (Örn: Sipariş sayısı, Hata oranı) Prometheus/Grafana için dışa aktar.
  • [ ] Log Centralization: Dağınık logları ELK (Elasticsearch/Logstash/Kibana) veya Datadog gibi bir merkezde topla.

Aşama 2: SLI/SLO & Alerting Setup

  • [ ] Defining SLIs: Başarı göstergelerini (Latency < 200ms, Error rate < %1) belirle.
  • [ ] Alert Groups: Kritik hataları (P0) telefon/PagerDuty üzerinden, bilgilendirme amaçlı olanları Slack üzerinden bildir.
  • [ ] Error Budget: SLO'nuzun ne kadar dışına çıkabileceğinizi (Hata Bütçesi) hesapla ve aşım yaklaştığında deployları durdur.

Aşama 3: Analysis & Incident Response

  • [ ] Dashboarding: Grafana üzerinde sistem sağlığını gösteren gerçek zamanlı panolar oluştur.
  • [ ] Post-Mortem: Her büyük olaydan (Incident) sonra kök neden analizi (Root Cause Analysis) yap ve dökümante et.
  • [ ] Automated Rollback: Kritik alert tetiklendiğinde sistemin otomatik bir önceki stabil versiyona dönmesini sağla.

Kontrol Noktaları

Aşama Doğrulama
1 Yeni bir servis eklendiğinde monitoring otomatik devreye giriyor mu?
2 Alertler "aksiyon alınabilir" (Actionable) bilgi içeriyor mu?
3 Loglarda PII (Kişisel veri) maskeleniyor mu?

Deploy Monitoring v1.5 - With Workflow

# Supported AI Coding Agents

This skill is compatible with the SKILL.md standard and works with all major AI coding agents:

Learn more about the SKILL.md standard and how to use these skills with your preferred AI coding agent.