This repository has been archived on 2024-12-15. You can view files and clone it, but cannot push or open issues or pull requests.
urbackup-internet-client/scripts/ftp_backup.sh

18 lines
341 B
Bash
Raw Normal View History

2022-10-09 11:33:33 +00:00
#!/usr/bin/env sh
2020-02-01 21:04:44 +00:00
REMOTE_DIR="/"
LOCAL_DIR="/backup/ftp"
2020-02-01 21:04:44 +00:00
echo
echo "Starting download $REMOTE_DIR from $FTP_HOST to $LOCAL_DIR"
date
lftp -u "$FTP_USER","$FTP_PASSWORD" $FTP_HOST <<EOF
set ssl:verify-certificate no
mirror --delete --parallel=4 --use-pget-n=10 $REMOTE_DIR $LOCAL_DIR;
exit
2022-10-09 12:42:33 +00:00
EOF || exit 1
2020-02-01 21:04:44 +00:00
echo
echo "Transfer finished"
date