--- interfaces: adm: eth0 srv_nat: eth1 loc_prometheus: node: file: targets_node.json targets: "{{ groups['server'] | select('match', '^.*\\.adm\\.ynerant\\.fr$') | list | sort }}" config: - job_name: servers file_sd_configs: - files: - '/etc/prometheus/targets_node.json' relabel_configs: - source_labels: [__address__] target_label: __param_target - source_labels: [__param_target] target_label: instance - source_labels: [__param_target] target_label: __address__ replacement: '$1:9100' nginx: file: targets_nginx.json targets: - proxy.adm.ynerant.fr config: - job_name: nginx file_sd_configs: - files: - '/etc/prometheus/targets_nginx.json' relabel_configs: - source_labels: [__address__] target_label: instance - source_labels: [instance] target_label: __address__ replacement: '$1:9117' blackbox: file: targets_blackbox.json targets: - https://ynerant.fr/ - https://bibliogram.ynerant.fr/ - https://element.ynerant.fr/ - https://gitea.ynerant.fr/ - https://grafana.ynerant.fr/ - https://hydrogen.ynerant.fr/ - https://nextcloud.ynerant.fr/ - https://mailu.ynerant.fr/ - http://notls.ynerant.fr/ - https://reddit.ynerant.fr/ - https://thelounge.ynerant.fr/ - https://translate.ynerant.fr/ - https://kfet.saperlistpopette.fr/ config: - job_name: blackbox file_sd_configs: - files: - '/etc/prometheus/targets_blackbox.json' metrics_path: /probe params: module: [http_2xx] # Look for a HTTP 200 response. relabel_configs: - source_labels: [__address__] target_label: __param_target - source_labels: [__param_target] target_label: instance - target_label: __address__ replacement: 127.0.0.1:9115