Add Node Exporter and Fail2Ban Exporter modules: implement Kubernetes resources and Prometheus scrape configurations
This commit is contained in:
@@ -135,3 +135,11 @@ module "prometheus" {
|
||||
persistent_folder = "${local.persistent_folder}/monitoring"
|
||||
config = file("${path.module}/resources/prometheus.yml")
|
||||
}
|
||||
|
||||
module "fail2ban_exporter" {
|
||||
source = "../../modules/utils/fail2ban-exporter"
|
||||
}
|
||||
|
||||
module "node_exporter" {
|
||||
source = "../../modules/utils/node-exporter"
|
||||
}
|
||||
|
||||
@@ -36,5 +36,11 @@ scrape_configs:
|
||||
regex: '^/system\.slice/(.+)\.service$'
|
||||
target_label: systemd_service_name
|
||||
replacement: "${1}"
|
||||
remote_write:
|
||||
- url: "http://prometheus.reverse-proxy.svc.cluster.local:9090/api/v1/write"
|
||||
- job_name: node-exporter
|
||||
scrape_interval: 10s
|
||||
static_configs:
|
||||
- targets: ["node-exporter.kube-system.svc.cluster.local:9100"]
|
||||
- job_name: fail2ban
|
||||
scrape_interval: 60s
|
||||
static_configs:
|
||||
- targets: ["fail2ban-exporter.kube-system.svc.cluster.local:9100"]
|
||||
|
||||
Reference in New Issue
Block a user