# Prometheus configuration
# Aut-O — T-12 Monitoring Stack

global:
  scrape_interval: 15s
  evaluation_interval: 15s
  scrape_timeout: 10s

rule_files:
  - "alert-rules.yml"

alerting:
  alertmanagers:
    - static_configs:
        - targets:
            - alertmanager:9093

scrape_configs:
  # Prometheus self-monitoring
  - job_name: "prometheus"
    static_configs:
      - targets: ["localhost:9090"]
        labels:
          service: "prometheus"

  # Node Exporter — host-level metrics (CPU, memory, disk, network)
  - job_name: "node-exporter"
    static_configs:
      - targets: ["node-exporter:9100"]
        labels:
          service: "node-exporter"

  # LLMHosts Python proxy — /metrics endpoint
  - job_name: "llmhosts-proxy"
    metrics_path: /metrics
    static_configs:
      - targets: ["llmhosts:4000"]
        labels:
          service: "llmhosts-proxy"

  # LLMHosts Next.js frontend — /api/metrics endpoint (if exposed)
  - job_name: "llmhosts-frontend"
    metrics_path: /api/metrics
    static_configs:
      - targets: ["llmhosts-frontend:3000"]
        labels:
          service: "llmhosts-frontend"

  # AlertManager
  - job_name: "alertmanager"
    static_configs:
      - targets: ["alertmanager:9093"]
        labels:
          service: "alertmanager"

  # Loki (if Loki exposes metrics)
  - job_name: "loki"
    static_configs:
      - targets: ["loki:3100"]
        labels:
          service: "loki"
