Having spent the last few days in Chef training, I needed to get a few notes out here.
Concepts
- Framework to solve business problems
- Infrastructure as code
- programmatically describe and manage infrastructure
- version controlled infrastructure
- simplified rebuilds
- Say what to change/configure, not how.
Relationships
This diagram is taken from the Opscode wiki and explains how the various parts of Chef fit together:
Recipes and Cookbooks
A lot of time after getting the concepts down, was spent typing. Most of that typing, was building recipes and cookbooks to do various things, the hard way. That is, instead of using knife or another tool to create nodes, recipes, cookbooks, etc, we built the files by hand.
Recipes, are the basic “unit” of a thing in Chef. From the OpsCode wiki:
Recipes are the fundamental configuration in Chef. Recipes encapsulate collections of resources which are executed in the order defined to configure the system.
Recipes are an internal Ruby domain-specific language (DSL), but you do not need to have experience with Ruby to write recipes.
Most things in Chef recipes will be resources to configure. Some things in recipes will be Ruby syntax and helper code.
Cookbooks, are collections of recipes, files, templates, and other resources.
Resources (for learning more Chef)
Again, these were some notes I needed to get written down. Some things that might be more useful to you:
- http://wiki.opscode.com/
- http://www.opscode.com/
- http://www.opscode.com/training/
- http://www.opscode.com/blog/2011/10/19/chef-training-guides/
- http://www.opscode.com/blog/2012/06/27/chef-for-openstack/
- http://wiki.opscode.com/display/chef/OpenStack+Bootstrap+Fast+Start+Guide
- http://www.slideshare.net/mattray/austin-openstack-meetup-feb-2012
- Update: http://www.siliconloons.com/?p=328 Also this.