Refactor tasks for compose.yml and add tasks for pihole, homeassistant, and prometheus
Signed-off-by: TuDatTr <tuan-dat.tran@tudattr.dev>
This commit is contained in:
@@ -8,7 +8,7 @@ global:
|
||||
# Attach these labels to any time series or alerts when communicating with
|
||||
# external systems (federation, remote storage, Alertmanager).
|
||||
external_labels:
|
||||
monitor: 'Mikrotik'
|
||||
monitor: 'tudattr'
|
||||
|
||||
# Alertmanager configuration
|
||||
alerting:
|
||||
@@ -37,18 +37,8 @@ scrape_configs:
|
||||
|
||||
#static_configs:
|
||||
#- targets: ['localhost:9090']
|
||||
|
||||
- job_name: Mikrotik
|
||||
- job_name: 'mikrotik'
|
||||
static_configs:
|
||||
- targets:
|
||||
- {{ mikrotik_ip }} # mikrotik_ip
|
||||
metrics_path: /snmp
|
||||
params:
|
||||
module: [mikrotik]
|
||||
relabel_configs:
|
||||
- source_labels: [__address__]
|
||||
target_label: __param_target
|
||||
- source_labels: [__param_target]
|
||||
target_label: instance
|
||||
- target_label: __address__
|
||||
replacement: mk_snmp_exporter:9116 # The SNMP exporter's real hostname:port.
|
||||
- "{{aya01_ip}}:{{ e_mikrotik_port }}"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user