Initial commit

This commit is contained in:
2022-05-07 18:07:35 +01:00
commit 8dc31ad258
15 changed files with 609 additions and 0 deletions

30
tasks/config.yaml Normal file
View File

@@ -0,0 +1,30 @@
---
- name: Create /etc/borgmatic folder
ansible.builtin.file:
path: /etc/borgmatic
state: directory
owner: root
group: root
mode: "0700"
- name: Write borgmatic config
template:
src: config.yaml.j2
dest: /etc/borgmatic/config.yaml
owner: root
group: root
mode: "0600"
- name: Create /root/.borgmatic folder
ansible.builtin.file:
path: /root/.borgmatic
state: directory
owner: root
group: root
mode: "0700"
- name: "Copy SSH key {{ item }} to borgmatic config folder"
ansible.builtin.copy:
src: "ssh_keys/{{ item }}"
dest: "/etc/borgmatic/{{ item }}"
owner: root
group: root
mode: "0600"
loop: "{{ borgmatic_ssh_keys }}"