From ce1458cf8a0c0732e717ce680d84d4667d7d3c37 Mon Sep 17 00:00:00 2001 From: John Keiser Date: Mon, 8 Aug 2016 13:32:59 -0700 Subject: Revert "Merge pull request #5123 from chef/lcg/resolv-replace" This reverts commit e8877cd363642ed6757c48d1ed5ab35509d87e22, reversing changes made to 162d988d3bcfce2773ef2831fa33e416f53731f6. --- lib/chef/application.rb | 4 ---- lib/chef/provider/file.rb | 8 -------- 2 files changed, 12 deletions(-) (limited to 'lib') diff --git a/lib/chef/application.rb b/lib/chef/application.rb index 7396051678..f9735a3769 100644 --- a/lib/chef/application.rb +++ b/lib/chef/application.rb @@ -29,10 +29,6 @@ require "tmpdir" require "rbconfig" require "chef/application/exit_code" require "yaml" -require "resolv" -# on linux, we replace the glibc resolver with the ruby resolv library, which -# supports reloading. -require "resolv-replace" if RbConfig::CONFIG["host_os"] =~ /linux/ class Chef class Application diff --git a/lib/chef/provider/file.rb b/lib/chef/provider/file.rb index bb0762ceb7..7f85085eeb 100644 --- a/lib/chef/provider/file.rb +++ b/lib/chef/provider/file.rb @@ -154,7 +154,6 @@ class Chef do_contents_changes do_acl_changes do_selinux - do_resolv_conf_fixup load_resource_attributes_from_file(@new_resource) end @@ -446,13 +445,6 @@ class Chef end end - def do_resolv_conf_fixup - # reload /etc/resolv.conf after we edit it -- only on linux -- and see lib/chef/application.rb - if new_resource.path == "/etc/resolv.conf" && RbConfig::CONFIG["host_os"] =~ /linux/ - Resolv::DefaultResolver.replace_resolvers [Resolv::DNS.new("/etc/resolv.conf")] - end - end - def do_acl_changes if access_controls.requires_changes? converge_by(access_controls.describe_changes) do -- cgit v1.2.1