diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2015-05-15 10:52:17 -0700 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2015-05-15 10:52:17 -0700 |
commit | d3b0f2ce30e4a8cbcbdd0c7128f4ae710a189e83 (patch) | |
tree | a4c129fb401e234bd767602ff9d097235ce7059a /lib/chef/knife.rb | |
parent | b086721ca70750277c407fd0cc573a08f076649f (diff) | |
download | chef-d3b0f2ce30e4a8cbcbdd0c7128f4ae710a189e83.tar.gz |
change default log_location + log_level for knife
send logging to STDERR and drop default log_level to :warn
so that we can see warnings again. logging needs to go to
STDERR so that we don't break someone's 'API' where they're piping
stdin to some filter. we believe the log_level was not warn
in order to suppress warns off of 404s which no longer warn by
default now.
Diffstat (limited to 'lib/chef/knife.rb')
-rw-r--r-- | lib/chef/knife.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/chef/knife.rb b/lib/chef/knife.rb index 4c59f831de..71215e7fbf 100644 --- a/lib/chef/knife.rb +++ b/lib/chef/knife.rb @@ -359,7 +359,7 @@ class Chef case Chef::Config[:verbosity] when 0, nil - Chef::Config[:log_level] = :error + Chef::Config[:log_level] = :warn when 1 Chef::Config[:log_level] = :info else @@ -401,6 +401,8 @@ class Chef end def configure_chef + # knife needs to send logger output to STDERR by default + Chef::Config[:log_location] = STDERR config_loader = self.class.load_config(config[:config_file]) config[:config_file] = config_loader.config_location |