On Mar 2, 2014, at 9:48 PM, Greg Zapp firstname.lastname@example.org wrote:
Thanks for those links; that stuff definitely looks interesting. I think for grabbing the logs out as they come I may just monkey patch my chef client to add a frame around what it would normally output to the log. That should let me grab out multi-line log entries no worries.
The problem with that method is that you will have created a private fork of the chef client, and you won’t be able to upgrade easily when the next version comes out. For example, if another SSL 0day type vulnerability was announced tomorrow, and a new version of chef client was created to address that problem, then you’d have to re-patch the new version with your changes.
Having a local fork like this of a piece of code that is well-maintained by someone else is a classic anti-pattern.
It will be a bit more work, but the right way to solve this problem is with your own local handler that you can keep separate from all the rest of the code, and easily bring with you when new versions of chef-client are shipped.
Of course, at the end of the day, if you want to load up a shotgun, pull the hammers back, and aim it at your foot, that’s your choice.
Brad Knowles email@example.com
LinkedIn Profile: http://tinyurl.com/y8kpxu