[chef] Re: Re: Where to store data bags


Chronological Thread 
  • From: Tensibai < >
  • To:
  • Subject: [chef] Re: Re: Where to store data bags
  • Date: Thu, 24 Sep 2015 16:33:45 +0200

To follow up on this idea I personally use the attribute approach, common attributes in attributes/default.rb and environments specific attributes in an attribute file per environment starting with a return in top of file to avoid reading the attributes in other environments.

QA.rb:

return unless node.chef_environment == 'QA'

# rest of attributes specific to QA environment

 

Le 2015-09-24 16:25, Fabien Delpierre a écrit :

Hi Cliff,
Just to throw something out there: instead of using data bags, why not just use an attribute and store the data as a hash? Functionally, there's very little difference, it should tie in well within your SDLC workflow, and it removes a modicum of complexity from the setup.
Fabien

On Thu, Sep 24, 2015 at 10:01 AM, Cliff Pracht < "> > wrote:
Hello,
 
I apologize if this has already been discussed on the list.
 
We are throwing around the idea of storing databags within the cookbook (that needs a particular settings).    We would have one databag per cookbook and one databag item per environment.   This seems like a good idea because the data that a said cookbook needs would be versioned within the cookbook and when it changes would require it to go through the SDLC.   Without this, someone could change data without using SDLC. 
 
Whether it is a Library or an app cookbooks, it would follow this same model. 
 
What are some thoughts of this? And how are people solving this today?
 
Thanks,
 
Cliff
 
 

 

 



Archive powered by MHonArc 2.6.16.

§