mirror of
https://cgit.krebsco.de/krops
synced 2024-11-30 06:59:46 +01:00
populate: support rsyncing files
This commit is contained in:
parent
e89cf20d43
commit
3022582ade
1 changed files with 5 additions and 1 deletions
|
@ -132,10 +132,14 @@ populate_file() {(
|
||||||
file_target=$target_user@$target_host:$target_path/$file_name
|
file_target=$target_user@$target_host:$target_path/$file_name
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if test -d "$file_path"; then
|
||||||
|
file_path=$file_path/
|
||||||
|
fi
|
||||||
|
|
||||||
rsync \
|
rsync \
|
||||||
-vFrlptD \
|
-vFrlptD \
|
||||||
--delete-excluded \
|
--delete-excluded \
|
||||||
"$file_path"/ \
|
"$file_path" \
|
||||||
-e "ssh -o ControlPersist=no -p $target_port" \
|
-e "ssh -o ControlPersist=no -p $target_port" \
|
||||||
"$file_target"
|
"$file_target"
|
||||||
)}
|
)}
|
||||||
|
|
Loading…
Reference in a new issue