mirror of
https://github.com/lintsinghua/DeepAudit.git
synced 2026-11-22 13:16:59 +08:00
44 lines
1009 B
YAML
44 lines
1009 B
YAML
# Prometheus Configuration for XCodeReviewer Backend
|
|
|
|
global:
|
|
scrape_interval: 15s
|
|
evaluation_interval: 15s
|
|
external_labels:
|
|
cluster: 'xcodereview'
|
|
environment: 'production'
|
|
|
|
# Alertmanager configuration
|
|
alerting:
|
|
alertmanagers:
|
|
- static_configs:
|
|
- targets:
|
|
- 'alertmanager:9093'
|
|
|
|
# Load rules once and periodically evaluate them
|
|
rule_files:
|
|
- 'prometheus_rules.yml'
|
|
|
|
# Scrape configurations
|
|
scrape_configs:
|
|
# Backend API metrics
|
|
- job_name: 'xcodereview-backend'
|
|
static_configs:
|
|
- targets: ['backend:8000']
|
|
metrics_path: '/metrics'
|
|
scrape_interval: 10s
|
|
|
|
# Prometheus self-monitoring
|
|
- job_name: 'prometheus'
|
|
static_configs:
|
|
- targets: ['localhost:9090']
|
|
|
|
# Redis metrics (if redis_exporter is used)
|
|
- job_name: 'redis'
|
|
static_configs:
|
|
- targets: ['redis-exporter:9121']
|
|
|
|
# PostgreSQL metrics (if postgres_exporter is used)
|
|
- job_name: 'postgresql'
|
|
static_configs:
|
|
- targets: ['postgres-exporter:9187']
|