diff options
Diffstat (limited to 'chef')
-rwxr-xr-x | chef/bin/chef-client | 2 | ||||
-rw-r--r-- | chef/lib/chef/daemon.rb | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/chef/bin/chef-client b/chef/bin/chef-client index df06e068fd..1c1b38bd19 100755 --- a/chef/bin/chef-client +++ b/chef/bin/chef-client @@ -79,6 +79,8 @@ end Chef::Config.from_file(config[:config_file]) Chef::Config.configure { |c| c.merge!(config) } +Chef::Daemon.change_privilege + if Chef::Config[:daemonize] unless Chef::Config[:log_location].is_a? IO Chef::Log.init(Chef::Config[:log_location]) diff --git a/chef/lib/chef/daemon.rb b/chef/lib/chef/daemon.rb index 7ab66ab710..1b4d770207 100644 --- a/chef/lib/chef/daemon.rb +++ b/chef/lib/chef/daemon.rb @@ -40,7 +40,6 @@ class Chef exit if fork Process.setsid exit if fork - change_privilege Chef::Log.info("Forked, in #{Process.pid}. Priveleges: #{Process.euid} #{Process.egid}") File.umask 0000 $stdin.reopen("/dev/null") |