[chef] Re: Re: Cannot find a cookbook named...


Chronological Thread 
  • From: Russell Bateman < >
  • To:
  • Subject: [chef] Re: Re: Cannot find a cookbook named...
  • Date: Wed, 26 Jun 2013 08:49:51 -0600

Sacha, Brad,

Bingo!

At first, I didn't see what inter-dependency existed especially as I was only thinking about the two, mongodb and tomcat6, recipes in hand.

In fact, as an extreme beginner, I hadn't even thought about dependencies yet. But it dawned on me upon reading your comments (both posts) that the mongodb cookbook, which creates an error message containing the word "apt", must of course have a dependency on a cookbook for Aptitude, used to install MongoDB. I got that cookbook down from opscode and now all of them install. Rockin'!

(For the time being, Sacha, I've decided to try to steal opscode recipes, but I'll soon graduate to better opportunities of theft as I begin to recognize the virtues of recipes others are offering.)

Magic; and it gives me hope.

Profuse thanks for the new illumination on my horizon!

Russ


On 6/25/2013 6:13 PM, Brad Knowles wrote:
On Jun 25, 2013, at 5:39 PM, Sascha Bates 
< >
 wrote:

Hi Russ, what you are encountering here is cookbook dependencies.  These are 
documented in the metadata.rb of the cookbook:
https://github.com/edelight/chef-mongodb/blob/master/metadata.rb#L15

There are a couple of different ways to cope with dependency management. I 
believe you can use `knife cookbook site install` and that will also pull 
dependencies that are listed in a metadata file.
Also note that if you have two internal cookbooks which depend on each other, it is 
possible to upload them both with the same "knife cookbook upload cookbook1 
cookbook2" command.  This way, knife will search for dependencies not only the 
list of cookbooks that are currently on the server but also the ones that you are 
involved in uploading.

It's not a good idea (in general) to have two cookbooks that both depend on 
each other, but sometimes it happens, and knife gives you a way to deal with 
that problem.

--
Brad Knowles 
< >
LinkedIn Profile: <http://tinyurl.com/y8kpxu>





Archive powered by MHonArc 2.6.16.

§