DEVOPS-C-01: Replace hardcoded :latest with IMAGE_TAG placeholder in all 8
production K8s manifests. Update deploy-production.yml to sed-replace
IMAGE_TAG with commit SHA before kubectl apply (remove now-redundant
kubectl set image step).
DEVOPS-C-02: Configure Alertmanager — create alertmanager.yml with Slack +
email receivers (critical/warning/infra routes, inhibition rules). Add
alertmanager:v0.27.0 service to both docker-compose.observability.yml and
deployments/local/docker-compose.yml. Enable prometheus.yml target
(alertmanager:9093).
DEVOPS-C-03: Remove :latest from docker-build.yml main branch push. Now
only SHA tag is pushed for main; :staging+SHA for develop.
DEVOPS-C-04: Add 4 mkt-* services to deployments/local/docker-compose.yml
with unique host ports (facebook:5021, whatsapp:5022, x:5023, zalo:5024)
to eliminate port 5000 conflicts. Add corresponding Traefik routers and
load-balancer entries in infra/traefik/dynamic/routes.yml
(/api/v1/mkt/{facebook,whatsapp,x,zalo}).
Co-Authored-By: Paperclip <noreply@paperclip.ing>
144 lines
4.1 KiB
YAML
144 lines
4.1 KiB
YAML
# =============================================================================
|
|
# GoodGo Platform - Prometheus Configuration
|
|
# =============================================================================
|
|
# EN: Scrape configuration for all core microservices and infrastructure.
|
|
# VI: Cau hinh thu thap metrics cho tat ca dich vu va ha tang.
|
|
# =============================================================================
|
|
|
|
global:
|
|
scrape_interval: 15s
|
|
evaluation_interval: 15s
|
|
scrape_timeout: 10s
|
|
external_labels:
|
|
cluster: 'goodgo'
|
|
environment: 'development'
|
|
|
|
# ---------------------------------------------------------------------------
|
|
# Alert Rules
|
|
# ---------------------------------------------------------------------------
|
|
rule_files:
|
|
- 'rules/*.yml'
|
|
- 'alert-rules.yml'
|
|
|
|
# ---------------------------------------------------------------------------
|
|
# Alertmanager (configure when ready)
|
|
# ---------------------------------------------------------------------------
|
|
alerting:
|
|
alertmanagers:
|
|
- static_configs:
|
|
- targets: ['alertmanager:9093']
|
|
|
|
# ---------------------------------------------------------------------------
|
|
# Scrape Targets
|
|
# ---------------------------------------------------------------------------
|
|
scrape_configs:
|
|
# -------------------------------------------------------------------------
|
|
# Prometheus self-monitoring
|
|
# -------------------------------------------------------------------------
|
|
- job_name: 'prometheus'
|
|
static_configs:
|
|
- targets: ['localhost:9090']
|
|
|
|
# -------------------------------------------------------------------------
|
|
# Core Microservices (8 production-ready)
|
|
# -------------------------------------------------------------------------
|
|
- job_name: 'iam-service'
|
|
metrics_path: /metrics
|
|
scrape_interval: 15s
|
|
static_configs:
|
|
- targets: ['iam-service-net:8080']
|
|
labels:
|
|
service: 'iam'
|
|
tier: 'core'
|
|
|
|
- job_name: 'merchant-service'
|
|
metrics_path: /metrics
|
|
scrape_interval: 15s
|
|
static_configs:
|
|
- targets: ['merchant-service-net:8080']
|
|
labels:
|
|
service: 'merchant'
|
|
tier: 'core'
|
|
|
|
- job_name: 'order-service'
|
|
metrics_path: /metrics
|
|
scrape_interval: 15s
|
|
static_configs:
|
|
- targets: ['order-service-net:8080']
|
|
labels:
|
|
service: 'order'
|
|
tier: 'core'
|
|
|
|
- job_name: 'fnb-engine'
|
|
metrics_path: /metrics
|
|
scrape_interval: 15s
|
|
static_configs:
|
|
- targets: ['fnb-engine-net:8080']
|
|
labels:
|
|
service: 'fnb'
|
|
tier: 'core'
|
|
|
|
- job_name: 'wallet-service'
|
|
metrics_path: /metrics
|
|
scrape_interval: 15s
|
|
static_configs:
|
|
- targets: ['wallet-service-net:8080']
|
|
labels:
|
|
service: 'wallet'
|
|
tier: 'core'
|
|
|
|
- job_name: 'catalog-service'
|
|
metrics_path: /metrics
|
|
scrape_interval: 15s
|
|
static_configs:
|
|
- targets: ['catalog-service-net:8080']
|
|
labels:
|
|
service: 'catalog'
|
|
tier: 'core'
|
|
|
|
- job_name: 'inventory-service'
|
|
metrics_path: /metrics
|
|
scrape_interval: 15s
|
|
static_configs:
|
|
- targets: ['inventory-service-net:8080']
|
|
labels:
|
|
service: 'inventory'
|
|
tier: 'core'
|
|
|
|
- job_name: 'chat-service'
|
|
metrics_path: /metrics
|
|
scrape_interval: 15s
|
|
static_configs:
|
|
- targets: ['chat-service-net:8080']
|
|
labels:
|
|
service: 'chat'
|
|
tier: 'core'
|
|
|
|
# -------------------------------------------------------------------------
|
|
# Infrastructure
|
|
# -------------------------------------------------------------------------
|
|
- job_name: 'traefik'
|
|
metrics_path: /metrics
|
|
static_configs:
|
|
- targets: ['traefik:8080']
|
|
labels:
|
|
service: 'traefik'
|
|
tier: 'infra'
|
|
|
|
- job_name: 'redis'
|
|
metrics_path: /metrics
|
|
static_configs:
|
|
- targets: ['redis-exporter:9121']
|
|
labels:
|
|
service: 'redis'
|
|
tier: 'infra'
|
|
|
|
- job_name: 'rabbitmq'
|
|
metrics_path: /metrics
|
|
scrape_interval: 30s
|
|
static_configs:
|
|
- targets: ['rabbitmq:15692']
|
|
labels:
|
|
service: 'rabbitmq'
|
|
tier: 'infra'
|