summaryrefslogtreecommitdiff
path: root/lib/chef/provider/osx_profile.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/provider/osx_profile.rb')
-rw-r--r--lib/chef/provider/osx_profile.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/chef/provider/osx_profile.rb b/lib/chef/provider/osx_profile.rb
index 1a5484ccbf..ba63d4b02a 100644
--- a/lib/chef/provider/osx_profile.rb
+++ b/lib/chef/provider/osx_profile.rb
@@ -33,6 +33,7 @@ class Chef
current_resource.profile_name(new_resource.profile_name)
all_profiles = get_installed_profiles
+ # FIXME: stop mutating the desired state
new_resource.profile(
new_resource.profile ||
new_resource.profile_name
@@ -149,6 +150,7 @@ class Chef
::File.dirname(cookbook_file)
)
)
+ # FIXME: should use a real cookbook file, or document what this craziness is
remote_file = Chef::Resource::CookbookFile.new(
::File.join(
get_cache_dir,
@@ -180,6 +182,7 @@ class Chef
end
def write_profile_to_disk
+ # FIXME: use a real chef file resource and stop hacking up tempfiles directly
new_resource.path(Chef::FileCache.create_cache_path("profiles"))
tempfile = Chef::FileContentManagement::Tempfile.new(new_resource).tempfile
tempfile.write(@new_profile_hash.to_plist)