Files
ansible-fet/roles/backup/tasks/borg.yml
root (arriane) e086fa9c04 Add backupclient
2017-10-31 09:11:30 +01:00

22 lines
490 B
YAML

---
- name: install borg
apt: name="borgbackup" state=present
- name: create repositories
file:
path: "{{item.path}}"
state: directory
with_items: "{{backup.repositories}}"
- name: init borg repositories
command: "borg init {{item.path}} --encryption=none"
args:
creates: "{{item.path}}/README"
with_items: "{{backup.repositories}}"
- name: create READMES
template:
src=borg_README.j2
dest="{{item.path}}/README"
with_items: "{{backup.repositories}}"