From 34253a5c30c1ed09147864e9052d97a27f50d696 Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Thu, 12 Feb 2015 10:35:07 +0100 Subject: [PATCH] update missing bits for __rsync Signed-off-by: Nico Schottelius --- cdist/conf/type/__rsync/gencode-local | 10 +++++----- cdist/conf/type/__rsync/gencode-remote | 8 ++++---- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/cdist/conf/type/__rsync/gencode-local b/cdist/conf/type/__rsync/gencode-local index 71e47af1..6df79c97 100644 --- a/cdist/conf/type/__rsync/gencode-local +++ b/cdist/conf/type/__rsync/gencode-local @@ -1,10 +1,10 @@ -source_dir=$(cat "$__object/parameter/source-dir") +source=$(cat "$__object/parameter/source") remote_user=$(cat "$__object/parameter/remote-user") -if [ -f "$__object/parameter/destination-dir" ]; then - destination_dir=$(cat "$__object/parameter/destination-dir") +if [ -f "$__object/parameter/destination" ]; then + destination=$(cat "$__object/parameter/destination") else - destination_dir="$__object_id" + destination="$__object_id" fi set -- @@ -16,4 +16,4 @@ fi echo rsync -a \ --no-owner --no-group \ - -q "$@" "${source_dir}/" "${remote_user}@${__target_host}:$destination_dir" + -q "$@" "${source}/" "${remote_user}@${__target_host}:${destination}" diff --git a/cdist/conf/type/__rsync/gencode-remote b/cdist/conf/type/__rsync/gencode-remote index f1c6e4d7..93125112 100644 --- a/cdist/conf/type/__rsync/gencode-remote +++ b/cdist/conf/type/__rsync/gencode-remote @@ -1,7 +1,7 @@ -if [ -f "$__object/parameter/destination-dir" ]; then - destination_dir=$(cat "$__object/parameter/destination-dir") +if [ -f "$__object/parameter/destination" ]; then + destination=$(cat "$__object/parameter/destination") else - destination_dir="$__object_id" + destination="$__object_id" fi ownergroup="" @@ -13,5 +13,5 @@ if [ -f "$__object/parameter/group" ]; then fi if [ "$ownergroup" ]; then - echo chown -R "$ownergroup" "$destination_dir" + echo chown -R "$ownergroup" "$destination" fi