diff options
-rw-r--r-- | chef-config/lib/chef-config/config.rb | 6 | ||||
-rw-r--r-- | lib/chef/policy_builder/dynamic.rb | 2 | ||||
-rw-r--r-- | spec/unit/policy_builder/dynamic_spec.rb | 12 |
3 files changed, 1 insertions, 19 deletions
diff --git a/chef-config/lib/chef-config/config.rb b/chef-config/lib/chef-config/config.rb index d0363c22c7..f4759e6c17 100644 --- a/chef-config/lib/chef-config/config.rb +++ b/chef-config/lib/chef-config/config.rb @@ -491,12 +491,6 @@ module ChefConfig default :named_run_list, nil - # During initial development, users were required to set `use_policyfile true` - # in `client.rb` to opt-in to policyfile use. Chef Client now examines - # configuration, node json, and the stored node to determine if policyfile - # usage is desired. This flag is still honored if set, but is unnecessary. - default :use_policyfile, false - # Policyfiles can be used in a native mode (default) or compatibility mode. # Native mode requires Chef Server 12.1 (it can be enabled via feature flag # on some prior versions). In native mode, policies and associated diff --git a/lib/chef/policy_builder/dynamic.rb b/lib/chef/policy_builder/dynamic.rb index 84021ea611..8ce4f25bfa 100644 --- a/lib/chef/policy_builder/dynamic.rb +++ b/lib/chef/policy_builder/dynamic.rb @@ -173,7 +173,7 @@ class Chef end def policyfile_set_in_config? - config[:use_policyfile] || config[:policy_name] || config[:policy_group] + config[:policy_name] || config[:policy_group] end def policyfile_compat_mode_config? diff --git a/spec/unit/policy_builder/dynamic_spec.rb b/spec/unit/policy_builder/dynamic_spec.rb index d94b2a69a2..f014cd9f2e 100644 --- a/spec/unit/policy_builder/dynamic_spec.rb +++ b/spec/unit/policy_builder/dynamic_spec.rb @@ -131,18 +131,6 @@ describe Chef::PolicyBuilder::Dynamic do end - context "and :use_policyfile is set in Chef::Config" do - - before do - Chef::Config[:use_policyfile] = true - end - - it "uses the Policyfile implementation" do - expect(implementation).to be_a(Chef::PolicyBuilder::Policyfile) - end - - end - context "and policy_name and policy_group are set on Chef::Config" do before do |