This commit is contained in:
2024-03-14 10:51:56 -05:00
parent 948fb19ec2
commit a1d38c874d

View File

@@ -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