diff options
author | Tim Smith <tsmith@chef.io> | 2018-09-16 21:18:54 -0700 |
---|---|---|
committer | Tim Smith <tsmith@chef.io> | 2018-09-16 21:18:54 -0700 |
commit | 0990e98694644957a9d1ecad2b6b67586bc47692 (patch) | |
tree | 20bad44098ec535ed4213847eb02e331e963322d | |
parent | 6ede9657643cd397d858e32c61f01271af4bb9b3 (diff) | |
download | ohai-0990e98694644957a9d1ecad2b6b67586bc47692.tar.gz |
Remove the chdir to / when running ohaichdir
This is a legacy issue that doesn't seem to be a problem in the modern design of ohai. Additionally it's probably breaking minor / subtle things throughout plugins.
Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r-- | lib/ohai/application.rb | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/lib/ohai/application.rb b/lib/ohai/application.rb index 2944dc16..9f0c1526 100644 --- a/lib/ohai/application.rb +++ b/lib/ohai/application.rb @@ -87,10 +87,6 @@ class Ohai::Application end def run_application - # Always switch to a readable directory. Keeps subsequent Dir.chdir() {} - # from failing due to permissions when launched as a less privileged user. - Dir.chdir("/") - config[:invoked_from_cli] = true config[:logger] = Ohai::Log.with_child ohai = Ohai::System.new(config) |