On Tuesday, August 6, 2013 at 9:00 AM, Torben Knerr wrote:
Hi everybody,
I just noticed that setting the output formatter via solo.rb does not work:
log_level :warn
formatter "minimal"
When I run chef-solo -j dna.json -c solo.rb it picks up the correct log_level from solo.rb but still uses the "doc" formatter.
Running chef-solo -j dna.json -c solo.rb -F min works though, so it seems it just does not pick it up from solo.rb...
This was observed on Chef 11.4.4 and Chef 11.6.0.
Is this a known bug?
Cheers, Torben
Use add_formatter. Chef has support for multiple formatters, so that you could hypothetically have one that prints user readable output to the screen while another prints machine parseable output to a file (or send data over the network to a centralized storage system or whatever). The configuration settings are pretty basic right now (you only can configure a formatter name and a file path), and I'm sure people will bump into limitations once they really start using it, but that's why it is this way.
On Tue, Aug 6, 2013 at 6:07 PM, Daniel DeLeo dan@kallistec.com wrote:
On Tuesday, August 6, 2013 at 9:00 AM, Torben Knerr wrote:
Hi everybody,
I just noticed that setting the output formatter via solo.rb does not work:
log_level :warn
formatter "minimal"
When I run chef-solo -j dna.json -c solo.rb it picks up the correct
log_level from solo.rb but still uses the "doc" formatter.
Running chef-solo -j dna.json -c solo.rb -F min works though, so it
seems it just does not pick it up from solo.rb...
This was observed on Chef 11.4.4 and Chef 11.6.0.
Is this a known bug?
Cheers, Torben
Use add_formatter. Chef has support for multiple formatters, so that
you could hypothetically have one that prints user readable output to the
screen while another prints machine parseable output to a file (or send
data over the network to a centralized storage system or whatever). The
configuration settings are pretty basic right now (you only can configure a
formatter name and a file path), and I'm sure people will bump into
limitations once they really start using it, but that's why it is this way.
Oh, is there a difference / inconsistency between chef-client and chef-solo?
@miketheman reports that formatter works with chef-client:
On Tue, Aug 6, 2013 at 7:48 PM, Torben Knerr ukio@gmx.de wrote:
Thanks, add_formatter works!
On Tue, Aug 6, 2013 at 6:07 PM, Daniel DeLeo dan@kallistec.com wrote:
On Tuesday, August 6, 2013 at 9:00 AM, Torben Knerr wrote:
Hi everybody,
I just noticed that setting the output formatter via solo.rb does not
work:
log_level :warn
formatter "minimal"
When I run chef-solo -j dna.json -c solo.rb it picks up the correct
log_level from solo.rb but still uses the "doc" formatter.
Running chef-solo -j dna.json -c solo.rb -F min works though, so it
seems it just does not pick it up from solo.rb...
This was observed on Chef 11.4.4 and Chef 11.6.0.
Is this a known bug?
Cheers, Torben
Use add_formatter. Chef has support for multiple formatters, so that
you could hypothetically have one that prints user readable output to the
screen while another prints machine parseable output to a file (or send
data over the network to a centralized storage system or whatever). The
configuration settings are pretty basic right now (you only can configure a
formatter name and a file path), and I'm sure people will bump into
limitations once they really start using it, but that's why it is this way.