[chef] Re: Re: Rebuild my chef !


Chronological Thread 
  • From: Andrew Gross < >
  • To: chef < >
  • Subject: [chef] Re: Re: Rebuild my chef !
  • Date: Mon, 6 May 2013 13:08:45 -0400

Regarding how to manage cookbooks in environments.

1. I would NOT use a different branch for staging vs prod chef environments.  

It is too easy to push the wrong one to the wrong place.  Our solution is to just use master branch for a cookbook and upload versions to prod/staging as needed.  All cookbook versions are locked in environments with --freeze so that we are forced to use good versioning practices when uploading.

Write a simple wrapper script to upload a cookbook to staging or prod.  Also, check out knife-spork for workflow help.


On Mon, May 6, 2013 at 1:00 PM, Jeremy Voorhis < " target="_blank"> > wrote:
Having undertaken a similar endeavor, I'll share one trick that worked for me:

If you're not already using a site-cookbooks directory, create one and move all of your existing cookbooks into it. (You may need to reconfigure your knife.rb.) Now, you can split each cookbook into its own repo and manage it with Berkshelf.


Ohai Chefs!

At my org we still have a monolithic chef-repo, with very little testing.. lets say the old way, being said that
I'm looking for advice/comments on how to rebuild this. Things that I think are no brainer:

- Have a chef server per environment: hosted chef for prod, ideally will be good to have for the others env too, but monay is the constrain here so OS for non prod env
- Use a git repo per cookbook
- use berkshelf
- test all the things (foodcritic, test-kitchen, chef-spec, mini-test)

Still I can't decide what to do with environment regarding cookbooks, have a branch per environment, like master(prod), test, dev or use
another method

Any other comments, ideas, recommendations are welcome

Thanks for being an awesome community :)

--
Jorge Espada




--
Jeremy Voorhis




Archive powered by MHonArc 2.6.16.

§