Browse Source

Modify icinga-client role to add some systemd options

nextgen
staticsafe 4 years ago
parent
commit
279b4e10f0
  1. 2
      ubuntu/roles/icinga-client/files/restart.conf
  2. 9
      ubuntu/roles/icinga-client/tasks/main.yml

2
ubuntu/roles/icinga-client/files/restart.conf

@ -0,0 +1,2 @@
[Service]
Restart=on-failure

9
ubuntu/roles/icinga-client/tasks/main.yml

@ -10,7 +10,16 @@
with_items:
- icinga2
- monitoring-plugins
- name: Ensure icinga2 systemd folder exists
file:
path: /etc/systemd/system/icinga2.service.d/
state: directory
- name: Copy custom icinga2 systemd service file modifications
copy:
src: restart.conf
dest: /etc/systemd/system/icinga2.service.d/restart.conf
- name: Ensure that icinga2 systemd service is enabled
systemd:
name: icinga2
enabled: yes
daemon_reload: yes

Loading…
Cancel
Save