parent
8bd3b79b89
commit
471a2ef915
|
@ -6,6 +6,12 @@
|
||||||
# todo: rename this script since it's a universal one?
|
# todo: rename this script since it's a universal one?
|
||||||
#
|
#
|
||||||
|
|
||||||
|
# user=$1
|
||||||
|
# pass=$2
|
||||||
|
# host=$3
|
||||||
|
# destination_folder=$4
|
||||||
|
# file_to_upload=$5
|
||||||
|
|
||||||
if [ ! "$1" ] || [ ! "$2" ] || [ ! "$3" ]; then
|
if [ ! "$1" ] || [ ! "$2" ] || [ ! "$3" ]; then
|
||||||
echo "No Secrets"
|
echo "No Secrets"
|
||||||
exit 0
|
exit 0
|
||||||
|
@ -13,4 +19,7 @@ fi
|
||||||
|
|
||||||
echo -e "\nUploading file: $5"
|
echo -e "\nUploading file: $5"
|
||||||
|
|
||||||
ncftpput -r 999 -m -R -v -u "$1" -p "$2" "$3" $4 $5
|
# ncftpput -r 999 -m -R -v -u "$1" -p "$2" "$3" $4 $5
|
||||||
|
|
||||||
|
echo put $5 $4 > cmd
|
||||||
|
sshpass -p $2 sftp -o StrictHostKeyChecking=no $1@$3 <<< `cat cmd`
|
Loading…
Reference in New Issue