Files
Terraform/roles/lib/setup-restic.yml
tolerryan 2d4e0b2fb7 test
2024-10-17 21:50:17 -05:00

36 lines
822 B
YAML

---
- name: backup your homefolders to /mnt/backup everyday night
hosts: all
become: yes
remote_user: ansible
gather_facts: false
#roles:
# - {role: roles-ansible.restic , tags: restic}
vars:
restic_create_schedule: true
restic_repos:
misamisa:
location: sftp:misamisa://home/restic/
password: 'ChangM3'
init: true
restic_backups:
home:
name: home
repo: misamisa
src: /home/
scheduled: true
schedule_oncalendar: '*-*-* 01:00:00'
tasks:
- name: Create SSH config file
copy:
dest: /home/docker/.ssh/config
content: |
Hostname misamisa.duckdns.org
Port 25456
User restic
IdentityFile vm
owner: docker
group: docker
mode: '0640'