[cluster] deploy: skip non-existing files

In "one-by-one" mode, test the existence of a file before to try to
transfer it.
This commit is contained in:
Matteo Cypriani 2013-05-20 14:36:02 -04:00
parent 2c6f1a97ea
commit 3a505db37b
1 changed files with 4 additions and 0 deletions

View File

@ -125,6 +125,10 @@ fi
# ... or one by one
for FILE in "$@" ; do
echo "Deploying '$FILE'..."
if [ ! -e "$FILE" ] ; then
echo "This file doesn't exist, skipping."
continue
fi
if [ "$RSYNC" = "1" ] ; then
$PRSYNC -a $DELETE $LOGIN -h "$HOSTS" -- "$FILE" "$DEST_DIR"
else