From 5ff1eac3e86990db4db2f07afd91b5d580c2932e Mon Sep 17 00:00:00 2001 From: Valentin Lab Date: Tue, 25 Jun 2024 10:53:37 +0200 Subject: [PATCH] fix: [rsync-backup-target] prevent error on ``init`` for missing file --- rsync-backup-target/hooks/init | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rsync-backup-target/hooks/init b/rsync-backup-target/hooks/init index ae662eb..dc53ea6 100755 --- a/rsync-backup-target/hooks/init +++ b/rsync-backup-target/hooks/init @@ -51,8 +51,8 @@ rebuild-config() { done < <(echo "$keys" | shyaml get-values-0) | file_put "$host_path_key/$ident/.ssh/authorized_keys" done < <(echo "$admin_keys" | shyaml -y key-values-0) + mkdir -p "${CONTROL_USERS_FILE%/*}" || return 1 e "$control_users" > "$CONTROL_USERS_FILE" - } local_path_key=/etc/rsync/keys/admin