lib/chef/provider/machine_file.rb in chef-metal-0.4 vs lib/chef/provider/machine_file.rb in chef-metal-0.5

- old
+ new

@@ -25,13 +25,20 @@ if new_resource.content machine.write_file(self, new_resource.path, new_resource.content) else machine.upload_file(self, new_resource.local_path, new_resource.path) end + + attributes = {} + attributes[:group] = new_resource.group if new_resource.group + attributes[:owner] = new_resource.owner if new_resource.owner + attributes[:mode] = new_resource.mode if new_resource.mode + + machine.set_attributes(self, new_resource.path, attributes) end action :download do - machine.download_file(provider, new_resource.path, new_resource.local_path) + machine.download_file(self, new_resource.path, new_resource.local_path) end action :delete do machine.delete_file(self, new_resource.path) end