upload.sh: Add option ssh_identity

Add config option ssh_identity

TODO: this obsoletes scp_pw and rsync_ssh_pw, remove them
This commit is contained in:
Jan Lindemann 2007-08-23 10:37:03 +00:00 committed by Jan Lindemann
commit 1a1fabeafd

View file

@ -43,9 +43,14 @@ file_mode=
dir_mode=
file_owner=
file_group=
ssh_identity=
test -f $CFG_FILE && . $CFG_FILE
if [ -n "$ssh_identity" ]; then
CFG_IDENTITY="-i $ssh_identity"
fi
usage()
{
cat << EOT
@ -86,6 +91,7 @@ cat << EOT
dir_mode="$dir_mode"
file_owner="$file_owner"
file_group="$file_group"
ssh_identity="$ssh_identity"
Options:
@ -117,7 +123,9 @@ parse_target()
if [ -n "$PASSWD" ]; then
echo passwd="\"$PASSWD\";"
if [ -f "$PASSWD" ]; then
echo IDENTITY="\"-i $PASSWD\""
echo IDENTITY="\"-i $PASSWD\";"
else
echo IDENTITY="\"$CFG_IDENTITY\";"
fi
echo pw_ftp="\"$PASSWD\";"
echo pw_scp="\"$PASSWD\";"