/chef_intro_repo

Simple Chef repository that shows you the first few steps through an example.

Primary LanguageRuby

Chef Intro repository

In this repository we solve some very basic tasks, it helps you practice Chef. Check the commit history to see the steps separately:

  1. Create a basic recipe that installs apache2. We create new apache cookbook, that only has a package resource in the default recipe, we create a new webserver role that we add to the run_list of the node.
  2. Use attributes. We specify default attributes in the cookbook, create a simple template that uses these attributes and override attributes in the role.
  3. Create a recipe that create a virtualhost named example.com. We create a directory and the virtualhost configuration from a template.
  4. Modify the previous recipe to go through all the items in a data bag and creates vhosts based on the data there.