From 37df1cf0bcc8405ba9d01245dd8cf6ebcceb426b Mon Sep 17 00:00:00 2001 From: danielsdeleo Date: Thu, 24 Sep 2015 13:28:34 -0700 Subject: Remove experimental feature warning for policyfiles Also, improve the language around unsupported features/options. --- lib/chef/policy_builder/policyfile.rb | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/lib/chef/policy_builder/policyfile.rb b/lib/chef/policy_builder/policyfile.rb index bb9593eb36..d6dcdf67b2 100644 --- a/lib/chef/policy_builder/policyfile.rb +++ b/lib/chef/policy_builder/policyfile.rb @@ -68,22 +68,20 @@ class Chef @node = nil - Chef::Log.warn("Using experimental Policyfile feature") - if Chef::Config[:solo] - raise UnsupportedFeature, "Policyfile does not support chef-solo at this time." + raise UnsupportedFeature, "Policyfile does not support chef-solo. Use chef-client local mode instead." end if override_runlist - raise UnsupportedFeature, "Policyfile does not support override run lists at this time" + raise UnsupportedFeature, "Policyfile does not support override run lists. Use named run_lists instead." end if json_attribs && json_attribs.key?("run_list") - raise UnsupportedFeature, "Policyfile does not support setting the run_list in json data at this time" + raise UnsupportedFeature, "Policyfile does not support setting the run_list in json data." end if Chef::Config[:environment] && !Chef::Config[:environment].chomp.empty? - raise UnsupportedFeature, "Policyfile does not work with Chef Environments" + raise UnsupportedFeature, "Policyfile does not work with Chef Environments." end end -- cgit v1.2.1