[chef] Re: Re: Load only definitions into my cookbook recipe


Chronological Thread 
  • From: Prajwal Manjunath < >
  • To:
  • Subject: [chef] Re: Re: Load only definitions into my cookbook recipe
  • Date: Mon, 20 May 2013 20:54:37 +0530

I tried adding a "depends 'nginx'" in metadata.rb and removing the include_recipe. It didn't work.
Anyway I noticed that the nginx cookbook isn't "supposed" to recompile on every include. It was caused by a bug where node.automaitc_attrs["nginx"] wasn't getting populated. I still haven't fixed it, but atleast now it's apparent the issue is with the nginx cookbook.


On Mon, May 20, 2013 at 8:46 PM, Daniel DeLeo < " target="_blank"> > wrote:

On Monday, May 20, 2013 at 4:29 AM, Prajwal Manjunath wrote:

I'm trying to use the nginx cookbook, which comes with a definition to "enable" sites.
I have a separate recipe for my application, which creates the nginx config for the app, and puts it in sites-available. I then try to use nginx_site definition.

The problem is, to do this, I have to "include_recipe 'nginx'"
 

This is problematic for me since I've configured it to install from source, and thus it recompiles nginx each time i try to deploy my app.

Is it possible to load only the definitions of the nginx cookbook into my recipe, so the nginx::default recipe doesn't run?
Definitions should be available as long as the cookbook gets loaded. Adding a dependency in the metadata of your custom cookbook should take care of this.

What happens if you just remove the include_recipe statement?


-- 
Daniel DeLeo
 





Archive powered by MHonArc 2.6.16.

§