lib/ridley/host_connector/winrm/worker.rb in ridley-0.10.2 vs lib/ridley/host_connector/winrm/worker.rb in ridley-0.11.0.rc1
- old
+ new
@@ -116,17 +116,16 @@
# @return [#run]
def chef_client
run("chef-client")
end
- # Executes a copy of the encrypted_data_bag_secret to the nodes
+ # Writes the given encrypted data bag secret to the node
#
- # @param [String] encrypted_data_bag_secret_path
- # the path to the encrypted_data_bag_secret
+ # @param [String] secret
+ # your organization's encrypted data bag secret
#
# @return [#run]
- def put_secret(encrypted_data_bag_secret_path)
- secret = File.read(encrypted_data_bag_secret_path).chomp
+ def put_secret(secret)
command = "echo #{secret} > C:\\chef\\encrypted_data_bag_secret"
run(command)
end
# Executes a provided Ruby script in the embedded Ruby installation