mirror of
https://github.com/vmstan/gravity-sync.git
synced 2024-08-30 18:22:11 +00:00
Duh
This commit is contained in:
parent
54efb9858a
commit
af11f11a6b
@ -153,9 +153,6 @@ function pull_gs {
|
||||
RSYNC_SOURCE="${PIHOLE_DIR}/${GRAVITY_FI}"
|
||||
RSYNC_TARGET="$HOME/${LOCAL_FOLDR}/${BACKUP_FOLD}/${GRAVITY_FI}.pull"
|
||||
create_rsynccmd
|
||||
${RSYNC_SEND} # >/dev/null 2>&1
|
||||
echo -en ${RSYNC_SEND}
|
||||
#error_validate
|
||||
|
||||
#${SSHPASSWORD} rsync -e "${SSH_CMD} -p ${SSH_PORT} -i $HOME/${SSH_PKIF}" ${REMOTE_USER}@${REMOTE_HOST}:${PIHOLE_DIR}/${GRAVITY_FI} $HOME/${LOCAL_FOLDR}/${BACKUP_FOLD}/${GRAVITY_FI}.pull >/dev/null 2>&1
|
||||
#error_validate
|
||||
@ -654,13 +651,13 @@ function create_rsynccmd {
|
||||
then
|
||||
if [ -z "$SSHPASSWORD" ]
|
||||
then
|
||||
RSYNC_SEND="rsync -e \"${SSH_CMD} -p ${SSH_PORT} -i $HOME/${SSH_PKIF}\" ${REMOTE_USER}@${REMOTE_HOST}:${RSYNC_SOURCE} ${RSYNC_TARGET}"
|
||||
rsync -e "${SSH_CMD} -p ${SSH_PORT} -i $HOME/${SSH_PKIF}\" ${REMOTE_USER}@${REMOTE_HOST}:${RSYNC_SOURCE} ${RSYNC_TARGET}
|
||||
else
|
||||
RSYNC_SEND="rsync -v -e ''${SSHPASSWORD} ${SSH_CMD} -p ${SSH_PORT} -i $HOME/${SSH_PKIF}'' ${REMOTE_USER}@${REMOTE_HOST}:${RSYNC_SOURCE} ${RSYNC_TARGET}"
|
||||
rsync -e "${SSHPASSWORD} ${SSH_CMD} -p ${SSH_PORT} -i $HOME/${SSH_PKIF}" ${REMOTE_USER}@${REMOTE_HOST}:${RSYNC_SOURCE} ${RSYNC_TARGET}
|
||||
fi
|
||||
elif hash dbclient 2>/dev/null
|
||||
then
|
||||
RSYNC_SEND="rsync -e \"${SSH_CMD} -p ${SSH_PORT} -i $HOME/${SSH_PKIF}\" ${REMOTE_USER}@${REMOTE_HOST}:${RSYNC_SOURCE} ${RSYNC_TARGET}"
|
||||
rsync -e "${SSH_CMD} -p ${SSH_PORT} -i $HOME/${SSH_PKIF}" ${REMOTE_USER}@${REMOTE_HOST}:${RSYNC_SOURCE} ${RSYNC_TARGET}
|
||||
fi
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user