Compare commits
3 commits
7119715720
...
c4b14cb447
Author | SHA1 | Date | |
---|---|---|---|
c4b14cb447 | |||
c5cc75e826 | |||
4ae69ceb89 |
8 changed files with 36 additions and 5 deletions
|
@ -227,6 +227,7 @@ firewall__forward:
|
|||
dst:
|
||||
- sw
|
||||
- ups
|
||||
- bmc
|
||||
protocols:
|
||||
udp:
|
||||
dport: 161
|
||||
|
|
13
group_vars/prom/prometheus/ilo.yml
Normal file
13
group_vars/prom/prometheus/ilo.yml
Normal file
|
@ -0,0 +1,13 @@
|
|||
---
|
||||
prometheus__scraping_ilo:
|
||||
targets: "{{ groups.ilo }}"
|
||||
address: 127.0.0.1:9116
|
||||
path: /snmp
|
||||
timeout: 180s
|
||||
interval: 180s
|
||||
params:
|
||||
module:
|
||||
- ilo
|
||||
|
||||
prometheus__rules_ilo: {}
|
||||
...
|
|
@ -10,6 +10,7 @@ prometheus__scraping:
|
|||
kresd: "{{ prometheus__scraping_kresd }}"
|
||||
bird: "{{ prometheus__scraping_bird }}"
|
||||
quanta: "{{ prometheus__scraping_quanta }}"
|
||||
ilo: "{{ prometheus__scraping_ilo }}"
|
||||
snmp: "{{ prometheus__scraping_snmp }}"
|
||||
eaton: "{{ prometheus__scraping_eaton }}"
|
||||
|
||||
|
@ -20,6 +21,7 @@ prometheus__rules:
|
|||
node: "{{ prometheus__rules_node }}"
|
||||
keepalived: "{{ prometheus__rules_keepalived }}"
|
||||
quanta: "{{ prometheus__rules_quanta }}"
|
||||
#ilo: "{{ prometheus__rules_ilo }}"
|
||||
bird: "{{ prometheus__rules_bird }}"
|
||||
#eaton: "{{ prometheus__rules_eaton }}"
|
||||
...
|
||||
|
|
|
@ -3,7 +3,8 @@ prometheus__scraping_quanta:
|
|||
targets: "{{ groups.quanta }}"
|
||||
address: 127.0.0.1:9116
|
||||
path: /snmp
|
||||
timeout: 60s
|
||||
timeout: 180s
|
||||
interval: 180s
|
||||
params:
|
||||
module:
|
||||
- quanta
|
||||
|
|
13
group_vars/prom/prometheus_snmp/ilo.yml
Normal file
13
group_vars/prom/prometheus_snmp/ilo.yml
Normal file
|
@ -0,0 +1,13 @@
|
|||
---
|
||||
prometheus_snmp__modules_ilo:
|
||||
version: 3
|
||||
auth:
|
||||
security_level: authPriv
|
||||
auth_protocol: SHA
|
||||
username: aurore
|
||||
password: "{{ vault_snmp_ilo_auth }}"
|
||||
priv_protocol: AES
|
||||
priv_password: "{{ vault_snmp_ilo_priv }}"
|
||||
walk:
|
||||
- sysUpTime
|
||||
...
|
|
@ -1,5 +1,6 @@
|
|||
---
|
||||
prometheus_snmp__modules:
|
||||
quanta: "{{ prometheus_snmp__modules_quanta }}"
|
||||
ilo: "{{ prometheus_snmp__modules_ilo }}"
|
||||
eaton: "{{ prometheus_snmp__modules_eaton }}"
|
||||
...
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
---
|
||||
systemd_link__links:
|
||||
adm0: 96:77:96:91:e3:6c
|
||||
ovh0: 00:50:56:00:fd:c0
|
||||
ovh0: 02:00:00:97:78:6d
|
||||
|
||||
ifupdown2__interfaces:
|
||||
adm0:
|
||||
|
|
|
@ -9,9 +9,7 @@ class FilterModule:
|
|||
|
||||
|
||||
def convert_jobs(config):
|
||||
|
||||
for name, job in config.items():
|
||||
|
||||
config = {
|
||||
"job_name": name,
|
||||
"static_configs": [
|
||||
|
@ -28,8 +26,10 @@ def convert_jobs(config):
|
|||
if "timeout" in job:
|
||||
config["scrape_timeout"] = job["timeout"]
|
||||
|
||||
if "address" in job:
|
||||
if "interval" in job:
|
||||
config["scrape_interval"] = job["interval"]
|
||||
|
||||
if "address" in job:
|
||||
try:
|
||||
replacement = f"$1:{job['address']['port']}"
|
||||
except Exception:
|
||||
|
|
Loading…
Reference in a new issue