Chef Fundamentals
Goal : Give a brief overview of Chef, the template variable, notifications and on
how to create a cookbooks.
Objectives : Upon completing this module, you should be able to: Understand about
Chef, Describe how Chef thinks about Infrastructure Automation, Learn how the
HAProxy works, Define the following terms: Node, Resource, Recipe, Cookbook, Run
List, Roles, Search.
Topics : Configuration Code, Organization, Environments, Controlling Idempotency,
Nodes, Resources and Recipes, Data bags, Search, HAProxy Configuration, HAProxy
Load Balancer, Using community cookbooks.
Chef Workstation and Node Setup
Goal : Demonstrate the setup of Chef Workstation and use knife in the Workstation.
Objectives : At the end of this module, you should be able to: Login to Enterprise
Chef, View your Organization in Enterprise Chef, Describe Knife, the Chef command
line utility, Use Knife on your Workstation, Install Chef nodes using "knife
bootstrap", Explain how knife bootstrap configures a node to use the Organization
created in the previous section, Explain the basic configuration needed to run
chef-client.
Topics : Chef Managed Infrastructure, ChefDK, Starter Kit, Knife, Chef -repo, .chef
Directory, Knife.rb, Nodes, Knife Bootstrap.
Practicals Covered : Install ChefDK, Creating Chef Account and the setup, Set up
the Workstation and Node
Chef Resources, Recipes and Resource Collection
Goal : Demonstrate the Cookbook creation, basics of recipe and how to use the
package, service and cookbook file resources.
Objectives : At the end of this module, you should be able to: Describe in detail
what a cookbook is, Create a new cookbook, Explain what a recipe is, Describe how
to use the package, service, and cookbook_file resources, Upload a cookbook to the
Chef Server, Explain what a run list is, and how to set it for a node via knife,
Explain the output of a chef-client run, List all the steps taken by a chef-client
during a run, Explain the basic security model of Chef, Explain the concepts of the
Resource Collection.
Topics : Cookbook, Chef Resources, Package, Resource Collection, Security Model of
Chef.
Practicals Covered : Create a new Cookbook, Upload a cookbook to the Chef Server
Introduction to Node Object, Node attribute and Cookbook Dependencies
Goal :Explain the Node Object and attributes in an organization and describe the
Cookbook Metadata and dependencies.
Objectives : At the end of this module, you should be able to: Explain what the
Node object represents in Chef, List the Nodes in an organization, Show details
about a Node, Describe what Node Attributes are, Retrieve a node attribute
directly, and via search, Describe where and how attributes are set, Explain the
attribute merge order and precedence rules, Declare an attribute with a recipe and
set its value, Describe Cookbook Attribute files, Use ERB Templates in Chef,
Explain Attribute Precedence, Describe Cookbook Metadata, Specify cookbook
dependencies, Perform the cookbook creation, upload, and test loop.
Topics : Node Object, Attribute Sources, Cookbook Metadata
Practicals Covered : Run Ohai on Mode, Setting attributes in Recipes, Upload the
cookbook
Template Variables, Controlling Idempotency and Recipe Inclusion
Goal : Describe the resources, template variables, loops and string expansion.
Objectives : At the end of this module, you should be able to: Use the execute
resource, Control idempotence manually with not_if and only_if, Navigate the
Resources page on docs.getchef.com, Describe the Directory resource, Implement
resource notifications, Explain what Template Variables are, and how to use them,
Use Ruby variables, loops, and string expansion.
Topics : Template Variables, Data Bags, Template Variable.
Practicals Covered : Write a User’s Cookbook.
Roles and Environments
Goal : Describe the environment and roles and use knife to work with Chef
Supermarket site API.
Objectives : At the end of this module, you should be able to: Describe what an
Environment is, and how it is different from an Organization, Set cookbook version
constraints, Explain when to set attributes in an environment, Find, preview and
download cookbooks from the Chef Supermarket community site, Use knife to work with
the Chef Supermarket site API, Download, extract, examine and implement cookbooks
from the Chef Supermarket.
Topics : Roles, Environments, Chef Supermarket, NTP Cookbook.
Practicals Covered : Create the Role, Re-run the Chef Client, Use NTP Cookbook