I use chef using chef-solo to bootstrap my ec2 instances etc.
Now currently I have a project where I have all my recipes in a folder:
I want to keep doing this for other projects, but obviously don’t want to
be duplicating my work.
Since recipes are suppose to work by themeselves (ignoring dependent
recipes), how would you recommend I organize things?
I was thinking of this:
- Have a git repo that has all my cookbook and recipes
- for my individual projects, I somehow link to this master git repo, and
then have whatever is specific to this project like:
**/cookbooks <-- git submodule of my main cookbooks
Does this make sense?
I think the key point to make sure things don’t break is for me to link to
the master /cookbooks git repo using a specific changeset/branch to ensure
things work even when I update the master cookbooks repo.
I’m guessing this is an obvious setup, but I just haven’t though things
through to set things up for multiple projects.
I’m not a big company, so I don’t need anything more eleborate than this
assuming it makes sense.
Is a git sub-module the way to go, I haven’t done this before so not sure
how to set this up, do you guys use rake?