ansible/roles/prometheus-apache-exporter/tasks/main.yml

17 lines
467 B
YAML

---
- name: Install prometheus-apache-exporter
ansible.builtin.apt:
update_cache: true
name: prometheus-apache-exporter
register: apt_result
retries: 3
until: apt_result is succeeded
- name: Make prometheus-apache-exporter listen on adm only
ansible.builtin.lineinfile:
path: /etc/default/prometheus-apache-exporter
regexp: ^ARGS=
line: |
ARGS="-telemetry.address={{ adm_ipv4 }}:9117"
notify: Restart prometheus-apache-exporter