From 0d3c51446d655fe25f2ca1ca1a56d0d74147b169 Mon Sep 17 00:00:00 2001 From: tolerryan <105945216+tolerryan@users.noreply.github.com> Date: Mon, 28 Oct 2024 00:33:26 -0500 Subject: [PATCH] work on restore --- roles/ind/wikmd/wikmd-install.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/roles/ind/wikmd/wikmd-install.yml b/roles/ind/wikmd/wikmd-install.yml index 0f90bf4..37e8b67 100644 --- a/roles/ind/wikmd/wikmd-install.yml +++ b/roles/ind/wikmd/wikmd-install.yml @@ -108,13 +108,18 @@ # project_src: /home/docker/ # register: output + - name: Check if wikmd directory exists + stat: + path: /data/wikmd + register: wikmd_stat + - name: Restore Wikmd Dir shell: | restic --password-file ./.resticpassword -r sftp:misamisa://home/restic/$(hostname) --target /data/wikmd restore latest args: chdir: /home/restic creates: /data/wikmd - when: not stat.wikmd.stat.exists or not stat.wikmd.stat.isdir + when: not wikmd_stat.stat.exists or not wikmd_stat.stat.isdir - name: Reload systemd daemon systemd: