[chef-dev] Re: Re: A strawman to fix platform dependencies

Chronological Thread 
  • From: Joseph Holsten < >
  • To: Ringo De Smet < >
  • Cc: " " < >
  • Subject: [chef-dev] Re: Re: A strawman to fix platform dependencies
  • Date: Thu, 22 Mar 2012 09:59:36 -0700

On Mar 22, 2012, at 7:59 AM, Ringo De Smet < "> > wrote:

He Joseph,

On 21 March 2012 22:06, Joseph Holsten < "> > wrote:
I think the ideal solution is to allow cookbooks to depend on *resources*, and select the cookbook with the appropriate *provider* based on platform support, environment constraints, &c.

I think "recipe-specificity" would also help here in having a clear cookbook implementation per platform, with some form of referring to the common parts in the parent platform.

Are you saying cookbooks should support a structure like this:


My first thought is that it would lead to a lot of repetition, but you could probably handle that with judicious use of definitions, libraries and lwrps.

My main objection is that my coworkers regularly get confused by that structure in files and templates. Beyond that, we've gotten to a ridiculous point in some recipes, saying:

case platform
  when 'redhat', 'centos', 'scientific', 'oracle', 'fedora', 'amazon'

I'd hate to see that reflected in file structure.


Archive powered by MHonArc 2.6.16.