Fetch database backups locally.

This commit is contained in:
2021-11-21 22:39:03 +01:00
parent c71f29c5ed
commit 14813c9b0b

View File

@@ -27,3 +27,12 @@
loop: "{{ lookup('dict', customers) }}"
loop_control:
label: "{{ item.key }}"
- name: Fetch backups
fetch:
src: {{ backup_dir }}/{{ item.key }}/db-{{ ansible_date_time.iso8601_basic_short }}.sql
dest: /backup/{{ item.key }}/db-{{ ansible_date_time.iso8601_basic_short }}.sql
flat: yes
loop: "{{ lookup('dict', customers) }}"
loop_control:
label: "{{ item.key }}"