mirror of
https://github.com/iiab/iiab.git
synced 2025-02-13 03:32:12 +00:00
Update main.yml
This commit is contained in:
parent
862c0d9db2
commit
3218bfe09b
1 changed files with 8 additions and 9 deletions
|
@ -5,7 +5,7 @@
|
|||
tags:
|
||||
- download
|
||||
|
||||
- name: Install chkconfig package -- not in Debian 8
|
||||
- name: Install chkconfig package (debian-8)
|
||||
package:
|
||||
name: chkconfig
|
||||
state: present
|
||||
|
@ -13,7 +13,7 @@
|
|||
tags:
|
||||
- download
|
||||
|
||||
- name: Update main config file
|
||||
- name: Install /etc/monitrc from template
|
||||
template:
|
||||
backup: yes
|
||||
src: monitrc
|
||||
|
@ -22,15 +22,14 @@
|
|||
group: root
|
||||
mode: 0600
|
||||
|
||||
- name: Update config files
|
||||
- name: Install config file /etc/monit.d/watchdog from template
|
||||
template:
|
||||
src: "{{ item }}"
|
||||
dest: "/etc/monit.d/{{ item }}"
|
||||
src: watchdog
|
||||
dest: /etc/monit.d/watchdog
|
||||
owner: root
|
||||
group: root
|
||||
force: yes
|
||||
mode: 0755
|
||||
with_items: watchdog
|
||||
register: monit_config
|
||||
when: false
|
||||
until: monit_config | success
|
||||
|
@ -38,16 +37,16 @@
|
|||
delay: 1
|
||||
|
||||
#TODO: create systemd script
|
||||
- name: Enable 'monit' service
|
||||
- name: Enable 'monit' service (chkconfig monit on)
|
||||
command: chkconfig monit on
|
||||
when: is_debian and ansible_local.local_facts.os_ver == "debian-8"
|
||||
|
||||
#- name: Restart monit service
|
||||
# command: service monit restart
|
||||
|
||||
- name: Add 'monit' to list of services at {{ iiab_ini_file }}
|
||||
- name: Add 'monit' variable values to {{ iiab_ini_file }}
|
||||
ini_file:
|
||||
dest: "{{ iiab_ini_file }}"
|
||||
path: "{{ iiab_ini_file }}"
|
||||
section: monit
|
||||
option: "{{ item.option }}"
|
||||
value: "{{ item.value }}"
|
||||
|
|
Loading…
Reference in a new issue