# Prometheus Configuration global: scrape_interval: 15s evaluation_interval: 15s external_labels: cluster: 'metabuilder' environment: '${ENVIRONMENT:-production}' # Alertmanager configuration alerting: alertmanagers: - static_configs: - targets: - alertmanager:9093 # Load alerting rules rule_files: - /etc/prometheus/alerts.yml # Scrape configurations scrape_configs: # Prometheus itself - job_name: 'prometheus' static_configs: - targets: ['localhost:9090'] # MetaBuilder Application - job_name: 'metabuilder-app' metrics_path: '/api/metrics' static_configs: - targets: ['metabuilder-app:3000'] relabel_configs: - source_labels: [__address__] target_label: instance replacement: 'metabuilder-app' # DBAL Daemon - job_name: 'dbal-daemon' metrics_path: '/metrics' static_configs: - targets: ['dbal-daemon:8080'] relabel_configs: - source_labels: [__address__] target_label: instance replacement: 'dbal-daemon' # Media Daemon - job_name: 'media-daemon' metrics_path: '/metrics' static_configs: - targets: ['media-daemon:8090'] relabel_configs: - source_labels: [__address__] target_label: instance replacement: 'media-daemon' # PostgreSQL - job_name: 'postgres' static_configs: - targets: ['postgres-exporter:9187'] relabel_configs: - source_labels: [__address__] target_label: instance replacement: 'postgres' # Redis - job_name: 'redis' static_configs: - targets: ['redis-exporter:9121'] relabel_configs: - source_labels: [__address__] target_label: instance replacement: 'redis' # Node Exporter (Host metrics) - job_name: 'node' static_configs: - targets: ['node-exporter:9100'] relabel_configs: - source_labels: [__address__] target_label: instance replacement: 'host' # cAdvisor (Container metrics) - job_name: 'cadvisor' static_configs: - targets: ['cadvisor:8080'] relabel_configs: - source_labels: [__address__] target_label: instance replacement: 'containers' # Nginx - job_name: 'nginx' metrics_path: '/metrics' static_configs: - targets: ['nginx:80'] relabel_configs: - source_labels: [__address__] target_label: instance replacement: 'nginx' # Icecast - job_name: 'icecast' metrics_path: '/status-json.xsl' static_configs: - targets: ['icecast:8000'] relabel_configs: - source_labels: [__address__] target_label: instance replacement: 'icecast'