2023-02-02 04:14:20 +00:00
|
|
|
- name: Install packages
|
|
|
|
package:
|
|
|
|
name:
|
|
|
|
- zrepl
|
|
|
|
state: present
|
|
|
|
|
2023-03-04 13:42:53 +00:00
|
|
|
- name: Create directories
|
|
|
|
file:
|
|
|
|
name: "{{ item }}"
|
|
|
|
state: directory
|
|
|
|
mode: 0755
|
|
|
|
owner: root
|
|
|
|
group: wheel
|
|
|
|
loop:
|
|
|
|
- /usr/local/etc/zrepl
|
|
|
|
|
|
|
|
- name: Configure zrepl
|
|
|
|
template:
|
|
|
|
src: templates/zrepl.yml.j2
|
|
|
|
dest: /usr/local/etc/zrepl/zrepl.yml
|
|
|
|
mode: 0440
|
|
|
|
owner: root
|
|
|
|
group: wheel
|
|
|
|
validate: "zrepl configcheck --config %s"
|
|
|
|
notify: "restart zrepl"
|
|
|
|
|
2022-10-11 23:52:53 +00:00
|
|
|
- name: Enable services
|
|
|
|
copy:
|
|
|
|
src: "files/{{ item.src }}"
|
|
|
|
dest: "{{ item.dest }}"
|
|
|
|
mode: 0644
|
|
|
|
owner: root
|
|
|
|
group: wheel
|
|
|
|
loop:
|
|
|
|
- src: rc.conf
|
|
|
|
dest: /etc/rc.conf.d/zrepl
|