blob: 932b4575d49c6e1836a9aeb086c3112f8d5fd991 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
---
# Blackbox Exporter for service level monitoring
- name: 'Copy the blackbox.yml config file to conf dir'
template:
src: 'blackbox.yml.j2'
dest: '{{ monitoring_root_dir }}/blackbox.yml'
mode: '0644'
- name: 'Make sure the blackbox exporter container is created and running'
docker_container:
name: 'blackbox-exporter'
image: 'prom/blackbox-exporter:v0.22.0'
pull: true
state: 'started'
recreate: true
command: '--config.file=/config/blackbox.yml'
volumes:
- "{{ monitoring_root_dir }}/blackbox.yml:/config/blackbox.yml"
network_mode: 'host'
restart_policy: unless-stopped
|