mongosb - move secret to dedicated file

This commit is contained in:
Ludovic Cartier
2021-05-31 14:44:26 +02:00
parent ff0533ecd3
commit f86870ec3a
3 changed files with 18 additions and 5 deletions

View File

@ -38,6 +38,16 @@
notify:
- 'prometheus | mongodb exporter | restart service'
- name: 'prometheus | mongodb exporter | configuration'
template:
src: conf/mongodb-exporter.conf.j2
dest: /etc/mongodb-exporter.conf
owner: root
group: root
mode: 0600
notify:
- 'prometheus | mongodb exporter | restart service'
- name: 'prometheus | mongodb exporter | configure systemd to use service'
systemd:
daemon_reload: yes