mirror of
https://gitea.0xace.cc/ansible-galaxy/wal-g.git
synced 2024-11-25 16:06:39 +00:00
30 lines
652 B
YAML
30 lines
652 B
YAML
|
- name: Install curl and jq
|
||
|
dnf:
|
||
|
name:
|
||
|
- jq
|
||
|
- curl
|
||
|
state: present
|
||
|
|
||
|
- name: Template backup script
|
||
|
template:
|
||
|
src: backup.sh.j2
|
||
|
dest: "{{ wal_g_pg_home_dir }}/backup.sh"
|
||
|
mode: 0755
|
||
|
owner: "{{ wal_g_pg_backup_owner }}"
|
||
|
group: "{{ wal_g_pg_backup_group }}"
|
||
|
|
||
|
- name: Template systemd backup service
|
||
|
template:
|
||
|
src: backup.service.j2
|
||
|
dest: /etc/systemd/system/backup.service
|
||
|
notify: Daemon reload backup service
|
||
|
register: backup_service
|
||
|
|
||
|
- name: Reload systemd backup service
|
||
|
systemd:
|
||
|
name: backup.service
|
||
|
enabled: no
|
||
|
masked: no
|
||
|
daemon_reload: yes
|
||
|
when: not backup_service.changed
|