I use and love Puppet. I moved to a new company and they are adopting Chef. So I'm trying to learn Chef but am having a hard time piecing it all together because I still think in Puppet =)
These are my questions:
- Is it better to setup roles in Ruby DSL, JSON, or from the management console? Why are there multiple ways to do the same thing?
- Can you organize cookbooks into subdirectories? eg: we have custom software that I'd like to write a cookbook for and stick that into: chef-repo/cookbooks/ourcompanystuff/customsoftwarecookbook would this be a good practice?
- Do I create a cookbook for each type of role that specifies what it does? Do I have these cookbooks include other cookbooks (i.e. the cookbook for my webserver role includes the apache cookbook). I'm not sure how cookbook inter-dependencies and inheritance are handled.
- Is there anything like Puppet's external node classifier so nodes automatically determine their roles?
- It seems like you can configure things with knife or within the management console, or editing JSON files? This is super confusing to me why there are so many ways to do things, it's paralyzing! Is there a reason to use one or the other? Coming from puppet it seems like it'd be easy to accidentally mis-configure something with these tools (i.e.- leaving something out)
- How can I automatically provision nodes with Chef in my dev cluster? With Puppet I fire up a VM that connects to the puppermaster and kicks off a puppet run and sets itself up (role is determined by external node classifier). How do I do this with Chef? Install chef with pem/rb files that tie it to a chef server, manually tell the node its roles with knife or editing this in the management interface, and then kicking off a chef-client run to set itself up?
I completed the getting started tutorials and I see they have EC2 tutorials, but I've never used EC2 so they're hard for me to follow. At this point I have hosted Chef running and I'm starting to play around with configuring a single node. Where do I go from here? Do I need to start looking at the public cookbooks?
The docs on Opscode are ok, but not nearly as great as Puppet's. Are there any other good Chef resources I might be missing in my searches?