You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

25 lines
561 B

- name: Install keepalived packages
apt:
name:
- keepalived
state: latest
update_cache: true
- name: Copy check_nginx script to {{ vrrp_check_nginx_script_path }}
copy:
src: check_nginx.sh
dest: "{{ vrrp_check_nginx_script_path }}"
owner: root
group: root
mode: 0755
- name: Copy keepalived config
template:
src: keepalived.conf.j2
dest: /etc/keepalived/keepalived.conf
- name: Restart and enable the keepalived service
ansible.builtin.service:
name: keepalived
state: restarted
enabled: yes