ops: add observability stack and SLO alerts

This commit is contained in:
2026-11-01 17:06:35 +03:00
parent 934dfefee7
commit 4bf383bd51
15 changed files with 1341 additions and 32 deletions
+44 -2
View File
@@ -1,6 +1,11 @@
global:
scrape_interval: 1s
evaluation_interval: 1s
scrape_interval: 2s
evaluation_interval: 5s
external_labels:
deployment_environment: lab
rule_files:
- /etc/prometheus/rules/*.yml
scrape_configs:
- job_name: messenger
@@ -9,6 +14,13 @@ scrape_configs:
type: A
port: 8080
refresh_interval: 2s
relabel_configs:
- target_label: service_name
replacement: messenger-api
metric_relabel_configs:
- source_labels: [__name__]
regex: "go_.*|process_.*"
action: keep
- job_name: nginx
static_configs:
@@ -32,12 +44,42 @@ scrape_configs:
type: A
port: 9091
refresh_interval: 2s
relabel_configs:
- target_label: service_name
replacement: messenger-worker
metric_relabel_configs:
- source_labels: [__name__]
regex: "go_.*|process_.*"
action: keep
- job_name: outbox-dispatcher
static_configs:
- targets: ["dispatcher:9091"]
relabel_configs:
- target_label: service_name
replacement: messenger-dispatcher
metric_relabel_configs:
- source_labels: [__name__]
regex: "go_.*|process_.*"
action: keep
- job_name: minio
metrics_path: /minio/v2/metrics/cluster
static_configs:
- targets: ["s3:9000"]
- job_name: otel-applications
static_configs:
- targets: ["otel-collector:8889"]
- job_name: otel-collector
static_configs:
- targets: ["otel-collector:8888"]
- job_name: tempo
static_configs:
- targets: ["tempo:3200"]
- job_name: loki
static_configs:
- targets: ["loki:3100"]