From a1d38c874d8906e8539fc0c4866bc3a04ad25d52 Mon Sep 17 00:00:00 2001 From: akanealw Date: Thu, 14 Mar 2024 10:51:56 -0500 Subject: [PATCH] testing --- restic/restic-sftp/install-restic-sftp.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/restic/restic-sftp/install-restic-sftp.sh b/restic/restic-sftp/install-restic-sftp.sh index 1baa20c..ea8c53e 100644 --- a/restic/restic-sftp/install-restic-sftp.sh +++ b/restic/restic-sftp/install-restic-sftp.sh @@ -13,7 +13,8 @@ mv /root/restic-sftp-* /root/scripts/restic mv /root/export-* /root/scripts/restic chmod +x /root/scripts/restic/* -isInFile=$(cat /root/.ssh/config | grep -c "truenas") > /dev/null 2>&1 +if [[ ! -f /root/.ssh/config ]]; then touch /root/.ssh/config +isInFile=$(cat /root/.ssh/config | grep -c "truenas") if [ $isInFile -eq 0 ] then echo "" >> /root/.ssh/config