[chef] Re: Re: Include a Recipe in a Provider


Chronological Thread 
  • From: Andrea Campi < >
  • To:
  • Subject: [chef] Re: Re: Include a Recipe in a Provider
  • Date: Thu, 29 Dec 2011 23:11:23 +0100

On Thu, Dec 29, 2011 at 8:31 PM, Joshua Timberman 
< >
 wrote:
> Hello,
>
> On Dec 29, 2011, at 12:04 PM, 
> < >
>  wrote:
>
>> Is it possible to include a recipe in a provider? I have tried using the
>> include_recipe function both inside the action definition and outside but 
>> it
>> doesn't seem to be available that way.
>
>
> No, include_recipe isn't available in cookbook providers/ directories.

Actually, there is a way:

action :create do
  run_context.include_recipe "apache2"

  ...
end


That works just fine in my experience.

Andrea



Archive powered by MHonArc 2.6.16.

§