computer-playbook/roles/native-docker-volume-backup/tasks/main.yml

27 lines
908 B
YAML
Raw Normal View History

2022-01-23 22:01:21 +01:00
- name: Install pandas python package
pip:
name: pandas
2021-10-18 13:37:20 +02:00
- name: pull docker-volume-backup.git
2020-12-24 14:27:31 +01:00
git:
repo: "https://github.com/kevinveenbirkenbach/docker-volume-backup.git"
2023-03-26 17:05:06 +02:00
dest: "{{docker_volume_backup_folder}}"
2020-12-24 14:27:31 +01:00
update: yes
2023-04-15 17:06:10 +02:00
- name: configure docker-volume-backup.service
template:
src: docker-volume-backup.service.j2
dest: /etc/systemd/system/docker-volume-backup.service
notify: reload docker-volume-backup service
2020-12-24 14:27:31 +01:00
- name: configure docker-volume-backup.timer.tpl
2023-03-26 17:05:06 +02:00
template: src=docker-volume-backup.timer.j2 dest=/etc/systemd/system/docker-volume-backup.timer
2020-12-24 14:27:31 +01:00
notify: restart docker-volume-backup timer
2022-01-23 21:43:05 +01:00
2023-03-26 23:29:30 +02:00
- name: create {{docker_volume_backup_folder}}databases.csv
2022-01-23 21:43:05 +01:00
copy:
2023-03-26 23:29:30 +02:00
src: "{{ inventory_dir }}/files/{{ inventory_hostname }}{{docker_volume_backup_folder}}databases.csv"
dest: "{{docker_volume_backup_folder}}databases.csv"
2022-01-23 21:43:05 +01:00
owner: root
group: root