[chef] Re: Preventing the deletion of cache when running chef-client -o


Chronological Thread 
  • From: Ranjib Dey < >
  • To:
  • Subject: [chef] Re: Preventing the deletion of cache when running chef-client -o
  • Date: Wed, 3 Apr 2013 13:10:58 -0700


try Chef::Config[:file_cache_path] to something other than the default one. I have used this trick to orchestrate multi-stage chef runs , 

if you want this to be done via command line, you might want to run the chef-client -o just_one_cookbook -c <a copy of knife config with a different file_cache_path>

regards
ranjib

On Wed, Apr 3, 2013 at 1:04 PM, Chris Sibbitt < " target="_blank"> > wrote:

Hi Chefs.

 

When I do a `chef-client –o just_one_cookbook` it removes all the other cookbooks from the cache because they are “no longer needed on this client”. Then next time a scheduled run occurs all the cookbooks get downloaded again. For various reasons I’d rather this didn’t happen.

 

I tried putting this in the client.rb file:

 

cache_options({ :skip_expires => true})

 

But it does not affect this behavior.

 

Can anyone point me to a way of preventing this cache cleanup when using an run_list override?

 

Thanks!

 





Archive powered by MHonArc 2.6.16.

§