Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #3016 - Change use of body class cf2_if_else by if_else in order to thrown class when promises kept #20

Merged
merged 1 commit into from
Dec 28, 2012
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions techniques/system/distributePolicy/1.0/propagatePromises.st
Original file line number Diff line number Diff line change
Expand Up @@ -35,31 +35,31 @@ bundle agent propagatePromises {
copy_from => copy("${g.rudder_base}/share/tools"),
depth_search => recurse_visible("inf"),
comment => "Fetching the tools for the promises execution",
classes => cf2_if_else("tools_propagated", "could_not_propagate_tools");
classes => if_else("tools_propagated", "could_not_propagate_tools");
!root_server::
"${client_data}" #that's a loop on each files in client_inputs
copy_from => remote("${server_info.cfserved}","${server_data}"),
depth_search => recurse_visible("inf"),
comment => "Fetching the promises to propagate",
classes => cf2_if_else("promises_propagated", "could_not_propagate_promise");
classes => if_else("promises_propagated", "could_not_propagate_promise");

"${g.rudder_dependencies}"
copy_from => remote("${server_info.cfserved}","${g.rudder_dependencies}"),
depth_search => recurse_visible("inf"),
comment => "Fetching the tools for the promises execution",
classes => cf2_if_else("tools_propagated", "could_not_propagate_tools");
classes => if_else("tools_propagated", "could_not_propagate_tools");

"$(sys.workdir)/masterfiles"
copy_from => remote("${server_info.cfserved}","$(sys.workdir)/masterfiles"),
depth_search => recurse_visible("inf"),
file_select => no_license_dat, #We don't want to propagate a wrong license.dat
comment => "Fetching the bootstrap promises",
classes => cf2_if_else("masterfiles_propagated", "could_not_propagate_masterfiles");
classes => if_else("masterfiles_propagated", "could_not_propagate_masterfiles");

"$(sys.workdir)/masterfiles/license.dat"
copy_from => local_cp("$(sys.workdir)/inputs/license.dat"),
comment => "Putting the right license in the bootstrap",
classes => cf2_if_else("license_copied", "could_not_copy_license");
classes => if_else("license_copied", "could_not_copy_license");

reports:
# Success if files are updated or not changed (kept or repaired).
Expand Down Expand Up @@ -91,14 +91,14 @@ bundle agent sendInventoryToCmdb {
transformer => "$(g.rudder_dependencies)/send-clean.sh &CMDBENDPOINT& $(this.promiser) ${g.rudder_inventories}/received/",
depth_search => recurse_visible(1),
file_select => all_files,
classes => cf2_if_else("inventory_sent", "cant_send_inventory"),
classes => if_else("inventory_sent", "cant_send_inventory"),
comment => "Sending the inventory to the cmdb";

"${g.rudder_inventories}/accepted-nodes-updates"
transformer => "$(g.rudder_dependencies)/send-clean.sh &CMDBENDPOINT& $(this.promiser) ${g.rudder_inventories}/received/",
depth_search => recurse_visible(1),
file_select => all_files,
classes => cf2_if_else("inventory_sent", "cant_send_inventory"),
classes => if_else("inventory_sent", "cant_send_inventory"),
comment => "Sending the inventory to the cmdb";


Expand Down