From 93253f7fda8157fe2bd4aa39a81311990252f4a3 Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Thu, 24 Feb 2011 15:05:31 +0100 Subject: [PATCH] export __target_host Signed-off-by: Nico Schottelius --- bin/cdist-config | 3 ++- bin/cdist-deploy-to | 8 +++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/bin/cdist-config b/bin/cdist-config index c1179b0d..6d9090b0 100755 --- a/bin/cdist-config +++ b/bin/cdist-config @@ -39,12 +39,13 @@ set -u : ${__cdist_name_manifest_dir:=manifests} : ${__cdist_name_out_dir:=out} : ${__cdist_name_conf_dir:=conf} +: ${__cdist_name_target_host:=target_host} : ${__cdist_name_type_bin:=type_bin} # Exported variable names (usable for non core) : ${__cdist_name_var_explorer:=__$__cdist_name_explorer} : ${__cdist_name_var_manifest:=__$__cdist_name_manifest_dir} - +: ${__cdist_name_var_target_host:=__$__cdist_name_target_host} # Name of the base directory containing the initial manifests : ${__cdist_name_manifests:=manifests} diff --git a/bin/cdist-deploy-to b/bin/cdist-deploy-to index cb6fc8da..7524e779 100755 --- a/bin/cdist-deploy-to +++ b/bin/cdist-deploy-to @@ -27,6 +27,9 @@ set -eu __cdist_target_host="$1" +# Make target host available for non-core +export $__cdist_name_var_target_host=\"\$__cdist_target_host\" + ################################################################################ # See cdist-stages(7) # @@ -43,12 +46,11 @@ cdist-bin-transfer "$__cdist_target_host" "$__cdist_remote_bin_dir" # Execute general explorers cdist-explorer-run-init "$__cdist_target_host" "$__cdist_out_explorer_dir" - -exit 2 - # Create initial object base cdist-manifest-run-init "$__cdist_target_host" "$__cdist_out_object_dir" +exit 2 + # Create dependent objects - BUG: does not abort on error in manifest!!!! cdist-manifest-run-all "$__cdist_target_host" "$__cdist_out_object_dir"