diff options
| author | Ahmed Abdelhalim <[email protected]> | 2025-09-15 22:17:49 +0200 |
|---|---|---|
| committer | Ahmed Abdelhalim <[email protected]> | 2025-09-15 22:26:15 +0200 |
| commit | d7c3044edf15ca2ee8a8bcc2fcdce8e26e4133d9 (patch) | |
| tree | 111df0a6afbf307b6ed9e7a112d02dffa506e892 /roles/prometheus/templates | |
| parent | 42899d44598c9cd848af1c86427f0b4c03f54493 (diff) | |
Add prometheus role (with node exporter)
Diffstat (limited to 'roles/prometheus/templates')
| -rw-r--r-- | roles/prometheus/templates/prometheus.yml.j2 | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/roles/prometheus/templates/prometheus.yml.j2 b/roles/prometheus/templates/prometheus.yml.j2 new file mode 100644 index 00000000..e39a69c0 --- /dev/null +++ b/roles/prometheus/templates/prometheus.yml.j2 @@ -0,0 +1,16 @@ +global: + scrape_interval: {{ prometheus_scrape_interval }} + evaluation_interval: {{ prometheus_scrape_interval }} + +rule_files: + +scrape_configs: + - job_name: 'prometheus' + static_configs: + - targets: ['localhost:{{ prometheus_port }}'] + + - job_name: 'node' + static_configs: + - targets: ['localhost:{{ prometheus_node_exporter_port }}'] + scrape_interval: {{ prometheus_scrape_interval }} + metrics_path: /metrics |
