Compare commits
No commits in common. "d555f919beefd91f0ea7492544b7a645e6f17ce3" and "48b0335071f7a4dcb074a63f80e8ebfa6a6c00e8" have entirely different histories.
d555f919be
...
48b0335071
@ -1,12 +1,12 @@
|
||||
## The playbook first runs the 'backup.yml' from each role
|
||||
- name: create the /backup-dirs file # this also runs on main in case someone doesn't run the backup.yml
|
||||
- name: create the /backup-dirs file
|
||||
file:
|
||||
path: "/backup-dirs"
|
||||
state: "touch"
|
||||
mode: "0400"
|
||||
changed_when: "true" # we always want ti give roles a chance to register dirs
|
||||
|
||||
- name: Ensure file contains lines from array # this also runs on main in case someone doesn't run the backup.yml
|
||||
- name: Ensure file contains lines from array
|
||||
lineinfile:
|
||||
path: /backup-dirs
|
||||
line: "{{ item }}"
|
||||
|
||||
@ -1,17 +1,5 @@
|
||||
- name: create the /backup-dirs file # this also runs on main in case someone doesn't run the backup.yml
|
||||
file:
|
||||
path: "/backup-dirs"
|
||||
state: "touch"
|
||||
mode: "0400"
|
||||
changed_when: "true" # we always want ti give roles a chance to register dirs
|
||||
|
||||
- name: Ensure file contains lines from array # this also runs on main in case someone doesn't run the backup.yml
|
||||
lineinfile:
|
||||
path: /backup-dirs
|
||||
line: "{{ item }}"
|
||||
create: yes
|
||||
state: present
|
||||
loop: "{{ extra_backup_paths }}"
|
||||
- debug:
|
||||
var: group_names
|
||||
|
||||
- name: make sure restic is installed
|
||||
apt: state=latest pkg=restic
|
||||
|
||||
@ -5,7 +5,6 @@ original_dir=$(pwd)
|
||||
source ./vars.sh
|
||||
cd "$original_dir"
|
||||
|
||||
(
|
||||
./mount.sh &
|
||||
RESTIC_PID=$!
|
||||
|
||||
@ -54,4 +53,3 @@ cd "$original_dir"
|
||||
umount /mnt/restic
|
||||
|
||||
echo "DONE"
|
||||
) >"/var/log/backup-restore-$(date +%s).log"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user