[EVO] Nettoyer le playbook
This commit is contained in:
parent
0d4cd47771
commit
4e38d48862
@ -13,7 +13,8 @@ keepalived_ipv6: ""
|
||||
|
||||
keepalived_peers: []
|
||||
|
||||
keepalived_notify_script_enabled: false
|
||||
keepalived_sudoers_files: []
|
||||
keepalived_notify_files: []
|
||||
|
||||
keepalived_track_scripts: []
|
||||
# Exemple:
|
||||
|
@ -16,24 +16,27 @@
|
||||
become: true
|
||||
notify: Redémarrer keepalived.service
|
||||
|
||||
- name: Déployer les scripts
|
||||
ansible.builtin.copy:
|
||||
src: keepalived/notify.sh
|
||||
dest: /etc/keepalived/
|
||||
owner: keepalived_script
|
||||
group: keepalived_script
|
||||
mode: u=rx,g=rx,o=
|
||||
when: keepalived_notify_script_enabled
|
||||
become: true
|
||||
notify: Redémarrer keepalived.service
|
||||
|
||||
- name: Déployer le fichier de configuration de sudoers
|
||||
ansible.builtin.copy:
|
||||
src: keepalived/sudoers
|
||||
src: "{{ item }}"
|
||||
dest: /etc/sudoers.d/keepalived
|
||||
owner: root
|
||||
group: root
|
||||
mode: u=rw,g=r,o=r
|
||||
validate: /usr/sbin/visudo -cf %s
|
||||
when: "'keepalived/sudoers' is file"
|
||||
when: item is file
|
||||
become: true
|
||||
loop: "{{ keepalived_sudoers_files }}"
|
||||
notify: Redémarrer keepalived.service
|
||||
|
||||
- name: Déployer les scripts
|
||||
ansible.builtin.copy:
|
||||
src: "{{ item }}"
|
||||
dest: /etc/keepalived/
|
||||
owner: keepalived_script
|
||||
group: keepalived_script
|
||||
mode: u=rx,g=rx,o=
|
||||
when: item is file
|
||||
become: true
|
||||
loop: "{{ keepalived_notify_files }}"
|
||||
notify: Redémarrer keepalived.service
|
||||
|
Loading…
Reference in New Issue
Block a user