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


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

He Joseph,

On 21 March 2012 22:06, Joseph Holsten < "> > wrote:
If you weren't following the CHEF-2988 thread earlier, there was mention of using a patch for allowed_recipes and restricted_recipes to help solve the platform dependency situation in chef. I've been building some stuff for windows, and I dislike adding depends "windows" to the mysql cookbook as much as anyone.

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.

Anyone else had this idea? Anyone have any thoughts on why it's a bad idea?

While the ticket you mention doesn't clearly mention the problem it tries to solve, I can neither see it linked to the platform dependency problem you refer to.

For the amount of cooking time I have spent so far, I did bump into issues where platform specific cookbook dependencies would help simplifying the implementation of some cookbooks. While cookbooks have file-specificity, a multi platform cookbook implementation could end up having a lot of case statements. 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.

With platform specific dependencies and recipe specificity, the run-time on a specific node could be optimal again without the proposed solution from the ticket.

My $.02. :-)

Ringo 



Archive powered by MHonArc 2.6.16.

§