SlideShare une entreprise Scribd logo
1  sur  61
Télécharger pour lire hors ligne
Chef Fundamentals
training@opscode.com
Copyright (C) 2013 Opscode, Inc.
Introductions
Nathen Harvey
• Technical Community Manager at Opscode
• Co-host of the Food Fight Show Podcast
• @nathenharvey
Webinar Objectives and Style
Multi-week Webinar Series
• After completing of this webinar series you will be
able to
• Automate common infrastructure tasks with Chef
• Describe Chef’s architecture
• Describe Chef’s various tools
• Apply Chef’s primitives to solve your problems
How to learn Chef
• You bring the domain expertise about your business
and problems
• Chef provides a framework for solving those
problems
• Our job is to work together to teach you how to
express solutions to your problems with Chef
Chef is a Language
• Learning Chef is like learning the basics of a
language
• 80% fluency will be reached very quickly
• The remaining 20% just takes practice
• The best way to learn Chef is to use Chef
Questions & Answers
• I’ll post objectives at the beginning of a section
• Ask questions in the chat window when they come to
you
• We’ll answer as many questions as we can at the
end of the session
• The webinar will be recorded and you’ll be able to
watch the recording again.
Agenda
Topics
• Overview of Chef
• Workstation Setup
• Test Node Setup
• Dissecting your first Chef run
• Introducing the Node object
• Writing your first cookbook
Topics
• Setting attributes, cookbook metadata, templates
• Idempotency, notifications, template variables
• Roles
• Using community cookbooks
• Further Resources
Overview of Chef
Lesson Objectives
• After completing the lesson, you will be able to
• Describe how Chef thinks about Infrastructure Automation
• Define the following terms:
• Node
• Resource
• Recipe
• Cookbook
• Run List
• Roles
• Search
Complexity

http://www.flickr.com/photos/michaelheiss/3090102907/
Items of Manipulation (Resources)
• Nodes
• Networking
• Files
• Directories
• Symlinks
• Mounts

• Routes
• Users
• Groups
• Packages
• Services
• Filesystems
A tale of growth...
Application
Add a database
Application

Application Database
Make database redundant
Application

App Databases
Application server redundancy
App Servers

App Databases
Add a load balancer
App LB

App Servers

App Databases
Webscale!
App LBs

App Servers

App Databases
Now we need a caching layer
App LBs
App Servers
App DB Cache
App DBs
Infrastructure has a Topology
App LBs
App Servers
App DB Cache
App DBs
Your Infrastructure is a Snowflake
Round Robin DNS
App Servers
App DB Cache
Floating IP?
App DBs
Complexity Increases Quickly
App LBs
Cache
App Servers
DB Cache

< Shiny!

DB slaves
DBs
Complexity Increases Quickly
App LBs
Cache
App Servers
DB Cache

< Shiny!

A

we
re

nito
mo

g??
rin

DB slaves
DBs
Chef Solves This Problem
™

• But you already
guessed that, didn’t
you?
Managing Complexity
• Organizations
• Environments
• Roles
• Nodes
• Recipes
• Cookbooks
• Search
Organizations
My Infrastructure

Your Infrastructure

Their Infrastructure
Organizations
• Completely independent tenants of Enterprise Chef
• Share nothing with other organizations
• May represent different
• Companies
• Business Units
• Departments
Environments
Development

Staging

Production
Environments
• Model the life-stages of your applications
• Every Organization starts with a single environment
• Environments to reflect your patterns and workflow
• Development
• Test
• Staging
• Production
• etc.
Environments Define Policy
• Environments may include data attributes necessary
for configuring your infrastructure
• The URL of your payment service’s API
• The location of your package repository
• The version of the Chef configuration files that
should be used
Roles
Load Balancers
Application Servers
DB Cache
Database
Roles
• Roles represent the types of servers in your
infrastructure
• Load Balancer
• Application Server
• Database Cache
• Database
• Monitoring
Roles Define Policy
• Roles may include a list of Chef configuration files
that should be applied.
• We call this list a Run List
• Roles may include data attributes necessary for
configuring your infrastructure
• The port that the application server listens on
• A list of applications that should be deployed
Nodes
Nodes
• Nodes represent the servers in your infrastructure
• Nodes may represent physical servers or virtual
servers
• Nodes may represent hardware that you own or may
represent compute instances in a public or private
cloud
Node
• Each Node will
• belong to one Organization
• belong to one Environment
• have zero or more Roles
Nodes Adhere to Policy
• An application, the chef-client, runs on each node
• chef-client will
• gather current system configuration
• download the desired system configuration from
the Chef server
• configure the node such that it adheres to the
policy
Chef is Infrastructure as Code

http://www.flickr.com/photos/louisb/4555295187/

• Programmatically
provision and
configure components
• Treat like any other
code base
• Reconstruct business
from code repository,
data backup, and bare
metal resources.
Configuration Code
• Chef ensures each Node complies with the policy
• Policy is determined by the configurations included
in each Node’s run list
• Reduce management complexity through abstraction
• Store the configuration of your infrastructure in
version control
Delcaritive Interface to Resources
• You define the policy in your Chef configuration
• Your policy states what state each resource should
be in, but not how to get there
• Chef-client will pull the policy from the Chef Server
and enforce the policy on the Node
Resources
• A Resource represents a piece of the system and its
desired state
• A package that should be installed
• A service that should be running
• A file that should be generated
• A cron job that should be configured
• A user that should be managed
• and more
Resources in Recipes
• Resources are the fundamental building blocks of
Chef configuration
• Resources are gathered into Recipes
• Recipes ensure the system is in the desired state
Recipes
• Configuration files that describe resources and their
desired state
• Recipes can:
• Install and configure software components
• Manage files
• Deploy applications
• Execute other recipes
• and more
Recipes
package "apache2"
template "/etc/apache2/apache2.conf" do
source "apache2.conf.erb"
owner "root"
group "root"
mode "0644"
variables(:allow_override => "All")
notifies :reload, "service[apache2]"
end
service "apache2" do
action [:enable,:start]
supports :reload => true
end
Cookbooks
• Recipes are stored in
Cookbooks
• Cookbooks contain recipes,
templates, files, custom
resources, etc
• Code re-use and modularity

http://www.flickr.com/photos/shutterhacks/4474421855/
Run List
Enterprise
Chef

What policy sho
uld

I follow?
chef-client

Node
Run List
Enterprise
Chef

What policy sho
uld

I follow?
chef-client

Node

“recipe[ntp::client]”
“recipe[users]”
“role[webserver]”
Run List
Enterprise
Chef

What policy sho
uld

I follow?
chef-client

“recipe[ntp::client]”
“recipe[users]”
“role[webserver]”
Run Lists Specifies Policy
• The Run List is a collection of policies that the Node
should follow.
• Chef-client obtains the Run List from the Chef
Server
• Chef-client ensures the Node complies with the
policy in the Run List
Search
• Search for nodes with Roles
• Find Topology Data
• IP addresses
• Hostnames
• FQDNs

http://www.flickr.com/photos/kathycsus/2686772625
So when this...
Graphite

Nagios

Jboss App
Memcache
Postgres Slaves
Postgres Master
...becomes this
Graphite

Nagios

Jboss App
Memcache
Postgres Slaves
Postgres Master
...this can happen automatically
Graphite

Nagios

Jboss App
Memcache
Postgres Slaves
Postgres Master
Count the Resources
Graphite

Nagios
Jboss App
Memcache
Postgres Slaves

• 12+ resource changes for 1 node addition

•
•
•
•
•
•
•
•
•
•
•

Load balancer config
Nagios host ping
Nagios host ssh
Nagios host HTTP
Nagios host app health
Graphite CPU
Graphite Memory
Graphite Disk
Graphite SNMP
Memcache firewall
Postgres firewall
Postgres authZ config
Manage Complexity
• Determine the desired state of your infrastructure
• Identify the Resources required to meet that state
• Gather the Resources into Recipes
• Compose a Run List from Recipes and Roles
• Apply a Run List to each Node in your Environment
• Your infrastructure adheres to the policy modeled in
Chef
Configuration Drift
• Configuration Drift happens when:
• Your infrastructure requirements change
• The configuration of a server falls out of policy
• Chef makes it easy to manage
• Model the new requirements in your Chef
configuration files
• Run the chef-client to enforce your policies
Recap
• In today’s webinar, we have
• Described how Chef thinks about Infrastructure Automation
• Defined the following terms:
• Node
• Resource
• Recipe
• Cookbook
• Run List
• Roles
• Search
What Questions Do You Have?
Nathen Harvey
Technical Community Manager, Opscode
nharvey@opscode.com
@nathenharvey

Contenu connexe

Tendances

Introduction to Chef
Introduction to ChefIntroduction to Chef
Introduction to ChefKnoldus Inc.
 
Chef ignited a DevOps revolution – BK Box
Chef ignited a DevOps revolution – BK BoxChef ignited a DevOps revolution – BK Box
Chef ignited a DevOps revolution – BK BoxChef Software, Inc.
 
Community Cookbooks & further resources - Fundamentals Webinar Series Part 6
Community Cookbooks & further resources - Fundamentals Webinar Series Part 6Community Cookbooks & further resources - Fundamentals Webinar Series Part 6
Community Cookbooks & further resources - Fundamentals Webinar Series Part 6Chef
 
Node object and roles - Fundamentals Webinar Series Part 3
Node object and roles - Fundamentals Webinar Series Part 3Node object and roles - Fundamentals Webinar Series Part 3
Node object and roles - Fundamentals Webinar Series Part 3Chef
 
Chef-Zero & Local Mode
Chef-Zero & Local ModeChef-Zero & Local Mode
Chef-Zero & Local ModeMichael Goetz
 
Chef Tutorial for DEVOPS Newbies
Chef Tutorial for DEVOPS NewbiesChef Tutorial for DEVOPS Newbies
Chef Tutorial for DEVOPS NewbiesMamun Rashid, CCDH
 
Chef Fundamentals Training Series Module 6: Roles, Environments, Community Co...
Chef Fundamentals Training Series Module 6: Roles, Environments, Community Co...Chef Fundamentals Training Series Module 6: Roles, Environments, Community Co...
Chef Fundamentals Training Series Module 6: Roles, Environments, Community Co...Chef Software, Inc.
 
Automating Infrastructure with Chef
Automating Infrastructure with ChefAutomating Infrastructure with Chef
Automating Infrastructure with ChefJennifer Davis
 
Chef vs Puppet vs Ansible vs SaltStack | Configuration Management Tools Compa...
Chef vs Puppet vs Ansible vs SaltStack | Configuration Management Tools Compa...Chef vs Puppet vs Ansible vs SaltStack | Configuration Management Tools Compa...
Chef vs Puppet vs Ansible vs SaltStack | Configuration Management Tools Compa...Edureka!
 
Environments - Fundamentals Webinar Series Week 5
Environments - Fundamentals Webinar Series Week 5Environments - Fundamentals Webinar Series Week 5
Environments - Fundamentals Webinar Series Week 5Chef
 
Overview of Chef - Fundamentals Webinar Series Part 1
Overview of Chef - Fundamentals Webinar Series Part 1Overview of Chef - Fundamentals Webinar Series Part 1
Overview of Chef - Fundamentals Webinar Series Part 1Chef
 
Infrastructure Automation with Chef
Infrastructure Automation with ChefInfrastructure Automation with Chef
Infrastructure Automation with ChefJonathan Weiss
 
Automating your infrastructure with Chef
Automating your infrastructure with ChefAutomating your infrastructure with Chef
Automating your infrastructure with ChefJohn Ewart
 
Common configuration with Data Bags - Fundamentals Webinar Series Part 4
Common configuration with Data Bags - Fundamentals Webinar Series Part 4Common configuration with Data Bags - Fundamentals Webinar Series Part 4
Common configuration with Data Bags - Fundamentals Webinar Series Part 4Chef
 

Tendances (20)

Introduction to Chef
Introduction to ChefIntroduction to Chef
Introduction to Chef
 
Chef ignited a DevOps revolution – BK Box
Chef ignited a DevOps revolution – BK BoxChef ignited a DevOps revolution – BK Box
Chef ignited a DevOps revolution – BK Box
 
Community Cookbooks & further resources - Fundamentals Webinar Series Part 6
Community Cookbooks & further resources - Fundamentals Webinar Series Part 6Community Cookbooks & further resources - Fundamentals Webinar Series Part 6
Community Cookbooks & further resources - Fundamentals Webinar Series Part 6
 
Node object and roles - Fundamentals Webinar Series Part 3
Node object and roles - Fundamentals Webinar Series Part 3Node object and roles - Fundamentals Webinar Series Part 3
Node object and roles - Fundamentals Webinar Series Part 3
 
Chef-Zero & Local Mode
Chef-Zero & Local ModeChef-Zero & Local Mode
Chef-Zero & Local Mode
 
Chef Tutorial for DEVOPS Newbies
Chef Tutorial for DEVOPS NewbiesChef Tutorial for DEVOPS Newbies
Chef Tutorial for DEVOPS Newbies
 
Chef Fundamentals Training Series Module 6: Roles, Environments, Community Co...
Chef Fundamentals Training Series Module 6: Roles, Environments, Community Co...Chef Fundamentals Training Series Module 6: Roles, Environments, Community Co...
Chef Fundamentals Training Series Module 6: Roles, Environments, Community Co...
 
Automating Infrastructure with Chef
Automating Infrastructure with ChefAutomating Infrastructure with Chef
Automating Infrastructure with Chef
 
Chef fundamentals
Chef fundamentalsChef fundamentals
Chef fundamentals
 
Chef vs Puppet vs Ansible vs SaltStack | Configuration Management Tools Compa...
Chef vs Puppet vs Ansible vs SaltStack | Configuration Management Tools Compa...Chef vs Puppet vs Ansible vs SaltStack | Configuration Management Tools Compa...
Chef vs Puppet vs Ansible vs SaltStack | Configuration Management Tools Compa...
 
Environments - Fundamentals Webinar Series Week 5
Environments - Fundamentals Webinar Series Week 5Environments - Fundamentals Webinar Series Week 5
Environments - Fundamentals Webinar Series Week 5
 
Overview of Chef - Fundamentals Webinar Series Part 1
Overview of Chef - Fundamentals Webinar Series Part 1Overview of Chef - Fundamentals Webinar Series Part 1
Overview of Chef - Fundamentals Webinar Series Part 1
 
Learning chef
Learning chefLearning chef
Learning chef
 
Opscode tech festa july 2013
Opscode tech festa   july 2013Opscode tech festa   july 2013
Opscode tech festa july 2013
 
Infrastructure Automation with Chef
Infrastructure Automation with ChefInfrastructure Automation with Chef
Infrastructure Automation with Chef
 
Introduction to chef
Introduction to chefIntroduction to chef
Introduction to chef
 
Understand Chef
Understand ChefUnderstand Chef
Understand Chef
 
Automating your infrastructure with Chef
Automating your infrastructure with ChefAutomating your infrastructure with Chef
Automating your infrastructure with Chef
 
Common configuration with Data Bags - Fundamentals Webinar Series Part 4
Common configuration with Data Bags - Fundamentals Webinar Series Part 4Common configuration with Data Bags - Fundamentals Webinar Series Part 4
Common configuration with Data Bags - Fundamentals Webinar Series Part 4
 
Chef introduction
Chef introductionChef introduction
Chef introduction
 

Similaire à Chef Fundamentals Training Series Module 1: Overview of Chef

TXLF: Chef- Software Defined Infrastructure Today & Tomorrow
TXLF: Chef- Software Defined Infrastructure Today & TomorrowTXLF: Chef- Software Defined Infrastructure Today & Tomorrow
TXLF: Chef- Software Defined Infrastructure Today & TomorrowMatt Ray
 
AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)
AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)
AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)Amazon Web Services
 
Introduction to Cooking with Chef
Introduction to Cooking with ChefIntroduction to Cooking with Chef
Introduction to Cooking with ChefJohn Osborne
 
Aai 3228-dev ops-tools-websphere-sl
Aai 3228-dev ops-tools-websphere-slAai 3228-dev ops-tools-websphere-sl
Aai 3228-dev ops-tools-websphere-slsflynn073
 
Chef for Openstack
Chef for OpenstackChef for Openstack
Chef for OpenstackMohit Sethi
 
Compliance Automation with InSpec
Compliance Automation with InSpecCompliance Automation with InSpec
Compliance Automation with InSpec Nathen Harvey
 
DOO-009_Powering High Velocity Development for your Infrastructure
DOO-009_Powering High Velocity Development for your InfrastructureDOO-009_Powering High Velocity Development for your Infrastructure
DOO-009_Powering High Velocity Development for your Infrastructuredecode2016
 
Using Nagios with Chef
Using Nagios with ChefUsing Nagios with Chef
Using Nagios with ChefBryan McLellan
 
Introduction to OpsWorks for Chef Automate
Introduction to OpsWorks for Chef AutomateIntroduction to OpsWorks for Chef Automate
Introduction to OpsWorks for Chef AutomateAmazon Web Services
 
Configuration Management with AWS OpsWorks for Chef Automate
Configuration Management with AWS OpsWorks for Chef AutomateConfiguration Management with AWS OpsWorks for Chef Automate
Configuration Management with AWS OpsWorks for Chef AutomateAmazon Web Services
 
2015 08-11-scdo-meetup
2015 08-11-scdo-meetup2015 08-11-scdo-meetup
2015 08-11-scdo-meetupSuresh Paulraj
 
Configuration Management in the Cloud - AWS Online Tech Talks
Configuration Management in the Cloud - AWS Online Tech TalksConfiguration Management in the Cloud - AWS Online Tech Talks
Configuration Management in the Cloud - AWS Online Tech TalksAmazon Web Services
 
Managing Distributed Systems with Chef
Managing Distributed Systems with ChefManaging Distributed Systems with Chef
Managing Distributed Systems with ChefMandi Walls
 
Managing Servers with Chef
Managing Servers with ChefManaging Servers with Chef
Managing Servers with ChefJoe Kepley
 
Designing your API Server for mobile apps
Designing your API Server for mobile appsDesigning your API Server for mobile apps
Designing your API Server for mobile appsMugunth Kumar
 

Similaire à Chef Fundamentals Training Series Module 1: Overview of Chef (20)

TXLF: Chef- Software Defined Infrastructure Today & Tomorrow
TXLF: Chef- Software Defined Infrastructure Today & TomorrowTXLF: Chef- Software Defined Infrastructure Today & Tomorrow
TXLF: Chef- Software Defined Infrastructure Today & Tomorrow
 
AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)
AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)
AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)
 
Introduction to Cooking with Chef
Introduction to Cooking with ChefIntroduction to Cooking with Chef
Introduction to Cooking with Chef
 
Aai 3228-dev ops-tools-websphere-sl
Aai 3228-dev ops-tools-websphere-slAai 3228-dev ops-tools-websphere-sl
Aai 3228-dev ops-tools-websphere-sl
 
Chef for Openstack
Chef for OpenstackChef for Openstack
Chef for Openstack
 
Chef for openstack
Chef for openstackChef for openstack
Chef for openstack
 
AWS OpsWorks for Chef Automate
AWS OpsWorks for Chef AutomateAWS OpsWorks for Chef Automate
AWS OpsWorks for Chef Automate
 
Compliance Automation with InSpec
Compliance Automation with InSpecCompliance Automation with InSpec
Compliance Automation with InSpec
 
DOO-009_Powering High Velocity Development for your Infrastructure
DOO-009_Powering High Velocity Development for your InfrastructureDOO-009_Powering High Velocity Development for your Infrastructure
DOO-009_Powering High Velocity Development for your Infrastructure
 
Using Nagios with Chef
Using Nagios with ChefUsing Nagios with Chef
Using Nagios with Chef
 
Introduction to OpsWorks for Chef Automate
Introduction to OpsWorks for Chef AutomateIntroduction to OpsWorks for Chef Automate
Introduction to OpsWorks for Chef Automate
 
Chef Jumpstart
Chef JumpstartChef Jumpstart
Chef Jumpstart
 
Chef Cookbook Workflow
Chef Cookbook WorkflowChef Cookbook Workflow
Chef Cookbook Workflow
 
Configuration Management with AWS OpsWorks for Chef Automate
Configuration Management with AWS OpsWorks for Chef AutomateConfiguration Management with AWS OpsWorks for Chef Automate
Configuration Management with AWS OpsWorks for Chef Automate
 
2015 08-11-scdo-meetup
2015 08-11-scdo-meetup2015 08-11-scdo-meetup
2015 08-11-scdo-meetup
 
Configuration Management in the Cloud - AWS Online Tech Talks
Configuration Management in the Cloud - AWS Online Tech TalksConfiguration Management in the Cloud - AWS Online Tech Talks
Configuration Management in the Cloud - AWS Online Tech Talks
 
Managing Distributed Systems with Chef
Managing Distributed Systems with ChefManaging Distributed Systems with Chef
Managing Distributed Systems with Chef
 
Way to cloud
Way to cloudWay to cloud
Way to cloud
 
Managing Servers with Chef
Managing Servers with ChefManaging Servers with Chef
Managing Servers with Chef
 
Designing your API Server for mobile apps
Designing your API Server for mobile appsDesigning your API Server for mobile apps
Designing your API Server for mobile apps
 

Plus de Chef Software, Inc.

Opscode Webinar: Cooking with Chef on Microsoft Windows
Opscode Webinar: Cooking with Chef on Microsoft WindowsOpscode Webinar: Cooking with Chef on Microsoft Windows
Opscode Webinar: Cooking with Chef on Microsoft WindowsChef Software, Inc.
 
Opscode Webinar: Automation for Education May 08-2013
Opscode Webinar: Automation for Education May 08-2013Opscode Webinar: Automation for Education May 08-2013
Opscode Webinar: Automation for Education May 08-2013Chef Software, Inc.
 
Utility HPC: Right Systems, Right Scale, Right Science
Utility HPC: Right Systems, Right Scale, Right ScienceUtility HPC: Right Systems, Right Scale, Right Science
Utility HPC: Right Systems, Right Scale, Right ScienceChef Software, Inc.
 
Using Kanban and Chef: A Case Study – Jeffrey Hulten
Using Kanban and Chef: A Case Study – Jeffrey HultenUsing Kanban and Chef: A Case Study – Jeffrey Hulten
Using Kanban and Chef: A Case Study – Jeffrey HultenChef Software, Inc.
 
SDN, Network Virtualization and the Software Defined Data Center – Brad Hedlund
SDN, Network Virtualization and the Software Defined Data Center – Brad HedlundSDN, Network Virtualization and the Software Defined Data Center – Brad Hedlund
SDN, Network Virtualization and the Software Defined Data Center – Brad HedlundChef Software, Inc.
 
ChefConf 2013 Keynote Session – Opscode – Adam Jacob
ChefConf 2013 Keynote Session – Opscode – Adam JacobChefConf 2013 Keynote Session – Opscode – Adam Jacob
ChefConf 2013 Keynote Session – Opscode – Adam JacobChef Software, Inc.
 
Using Chef and AppFirst to Automate Scale-out/Scale-down of Web Applications ...
Using Chef and AppFirst to Automate Scale-out/Scale-down of Web Applications ...Using Chef and AppFirst to Automate Scale-out/Scale-down of Web Applications ...
Using Chef and AppFirst to Automate Scale-out/Scale-down of Web Applications ...Chef Software, Inc.
 
The InstallShield of the 21st Century – Theo Schlossnagle
The InstallShield of the 21st Century – Theo SchlossnagleThe InstallShield of the 21st Century – Theo Schlossnagle
The InstallShield of the 21st Century – Theo SchlossnagleChef Software, Inc.
 
Push jobs: an orchestration building block for private Chef
Push jobs: an orchestration building block for private ChefPush jobs: an orchestration building block for private Chef
Push jobs: an orchestration building block for private ChefChef Software, Inc.
 
Multi-provider Vagrant and Chef: AWS, VMware, and more
Multi-provider Vagrant and Chef: AWS, VMware, and moreMulti-provider Vagrant and Chef: AWS, VMware, and more
Multi-provider Vagrant and Chef: AWS, VMware, and moreChef Software, Inc.
 
Welcome to the IT Industrial Revolution! Are you ready?
Welcome to the IT Industrial Revolution! Are you ready?Welcome to the IT Industrial Revolution! Are you ready?
Welcome to the IT Industrial Revolution! Are you ready?Chef Software, Inc.
 
Who Says Elephants Can’t Cook? How IBM and Opscode are changing the role of c...
Who Says Elephants Can’t Cook? How IBM and Opscode are changing the role of c...Who Says Elephants Can’t Cook? How IBM and Opscode are changing the role of c...
Who Says Elephants Can’t Cook? How IBM and Opscode are changing the role of c...Chef Software, Inc.
 
Growing Pains with Chef – a Tale of DevOps in a Large Organization
Growing Pains with Chef – a Tale of DevOps in a Large OrganizationGrowing Pains with Chef – a Tale of DevOps in a Large Organization
Growing Pains with Chef – a Tale of DevOps in a Large OrganizationChef Software, Inc.
 
Cookbook refactoring & abstracting logic to Ruby(gems)
Cookbook refactoring & abstracting logic to Ruby(gems)Cookbook refactoring & abstracting logic to Ruby(gems)
Cookbook refactoring & abstracting logic to Ruby(gems)Chef Software, Inc.
 
Creating a culture for Continuous Delivery
Creating a culture for Continuous DeliveryCreating a culture for Continuous Delivery
Creating a culture for Continuous DeliveryChef Software, Inc.
 
Cookin’ up Hybrid Clouds: Chef and the Accenture Cloud Platform
Cookin’ up Hybrid Clouds: Chef and the Accenture Cloud PlatformCookin’ up Hybrid Clouds: Chef and the Accenture Cloud Platform
Cookin’ up Hybrid Clouds: Chef and the Accenture Cloud PlatformChef Software, Inc.
 
Exploiting Conway’s Law for Underpants and Profit
 Exploiting Conway’s Law for Underpants and Profit Exploiting Conway’s Law for Underpants and Profit
Exploiting Conway’s Law for Underpants and ProfitChef Software, Inc.
 
Configuration management and #monitoringlove
Configuration management and #monitoringloveConfiguration management and #monitoringlove
Configuration management and #monitoringloveChef Software, Inc.
 

Plus de Chef Software, Inc. (20)

Opscode Webinar: Cooking with Chef on Microsoft Windows
Opscode Webinar: Cooking with Chef on Microsoft WindowsOpscode Webinar: Cooking with Chef on Microsoft Windows
Opscode Webinar: Cooking with Chef on Microsoft Windows
 
Opscode Webinar: Automation for Education May 08-2013
Opscode Webinar: Automation for Education May 08-2013Opscode Webinar: Automation for Education May 08-2013
Opscode Webinar: Automation for Education May 08-2013
 
Utility HPC: Right Systems, Right Scale, Right Science
Utility HPC: Right Systems, Right Scale, Right ScienceUtility HPC: Right Systems, Right Scale, Right Science
Utility HPC: Right Systems, Right Scale, Right Science
 
The Berkshelf Way
The Berkshelf WayThe Berkshelf Way
The Berkshelf Way
 
Using Kanban and Chef: A Case Study – Jeffrey Hulten
Using Kanban and Chef: A Case Study – Jeffrey HultenUsing Kanban and Chef: A Case Study – Jeffrey Hulten
Using Kanban and Chef: A Case Study – Jeffrey Hulten
 
SDN, Network Virtualization and the Software Defined Data Center – Brad Hedlund
SDN, Network Virtualization and the Software Defined Data Center – Brad HedlundSDN, Network Virtualization and the Software Defined Data Center – Brad Hedlund
SDN, Network Virtualization and the Software Defined Data Center – Brad Hedlund
 
ChefConf 2013 Keynote Session – Opscode – Adam Jacob
ChefConf 2013 Keynote Session – Opscode – Adam JacobChefConf 2013 Keynote Session – Opscode – Adam Jacob
ChefConf 2013 Keynote Session – Opscode – Adam Jacob
 
Using Chef and AppFirst to Automate Scale-out/Scale-down of Web Applications ...
Using Chef and AppFirst to Automate Scale-out/Scale-down of Web Applications ...Using Chef and AppFirst to Automate Scale-out/Scale-down of Web Applications ...
Using Chef and AppFirst to Automate Scale-out/Scale-down of Web Applications ...
 
The InstallShield of the 21st Century – Theo Schlossnagle
The InstallShield of the 21st Century – Theo SchlossnagleThe InstallShield of the 21st Century – Theo Schlossnagle
The InstallShield of the 21st Century – Theo Schlossnagle
 
The unintended benefits of Chef
The unintended benefits of ChefThe unintended benefits of Chef
The unintended benefits of Chef
 
Push jobs: an orchestration building block for private Chef
Push jobs: an orchestration building block for private ChefPush jobs: an orchestration building block for private Chef
Push jobs: an orchestration building block for private Chef
 
Multi-provider Vagrant and Chef: AWS, VMware, and more
Multi-provider Vagrant and Chef: AWS, VMware, and moreMulti-provider Vagrant and Chef: AWS, VMware, and more
Multi-provider Vagrant and Chef: AWS, VMware, and more
 
Welcome to the IT Industrial Revolution! Are you ready?
Welcome to the IT Industrial Revolution! Are you ready?Welcome to the IT Industrial Revolution! Are you ready?
Welcome to the IT Industrial Revolution! Are you ready?
 
Who Says Elephants Can’t Cook? How IBM and Opscode are changing the role of c...
Who Says Elephants Can’t Cook? How IBM and Opscode are changing the role of c...Who Says Elephants Can’t Cook? How IBM and Opscode are changing the role of c...
Who Says Elephants Can’t Cook? How IBM and Opscode are changing the role of c...
 
Growing Pains with Chef – a Tale of DevOps in a Large Organization
Growing Pains with Chef – a Tale of DevOps in a Large OrganizationGrowing Pains with Chef – a Tale of DevOps in a Large Organization
Growing Pains with Chef – a Tale of DevOps in a Large Organization
 
Cookbook refactoring & abstracting logic to Ruby(gems)
Cookbook refactoring & abstracting logic to Ruby(gems)Cookbook refactoring & abstracting logic to Ruby(gems)
Cookbook refactoring & abstracting logic to Ruby(gems)
 
Creating a culture for Continuous Delivery
Creating a culture for Continuous DeliveryCreating a culture for Continuous Delivery
Creating a culture for Continuous Delivery
 
Cookin’ up Hybrid Clouds: Chef and the Accenture Cloud Platform
Cookin’ up Hybrid Clouds: Chef and the Accenture Cloud PlatformCookin’ up Hybrid Clouds: Chef and the Accenture Cloud Platform
Cookin’ up Hybrid Clouds: Chef and the Accenture Cloud Platform
 
Exploiting Conway’s Law for Underpants and Profit
 Exploiting Conway’s Law for Underpants and Profit Exploiting Conway’s Law for Underpants and Profit
Exploiting Conway’s Law for Underpants and Profit
 
Configuration management and #monitoringlove
Configuration management and #monitoringloveConfiguration management and #monitoringlove
Configuration management and #monitoringlove
 

Dernier

Igniting Next Level Productivity with AI-Infused Data Integration Workflows
Igniting Next Level Productivity with AI-Infused Data Integration WorkflowsIgniting Next Level Productivity with AI-Infused Data Integration Workflows
Igniting Next Level Productivity with AI-Infused Data Integration WorkflowsSafe Software
 
UiPath Studio Web workshop series - Day 8
UiPath Studio Web workshop series - Day 8UiPath Studio Web workshop series - Day 8
UiPath Studio Web workshop series - Day 8DianaGray10
 
Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)Commit University
 
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Will Schroeder
 
Comparing Sidecar-less Service Mesh from Cilium and Istio
Comparing Sidecar-less Service Mesh from Cilium and IstioComparing Sidecar-less Service Mesh from Cilium and Istio
Comparing Sidecar-less Service Mesh from Cilium and IstioChristian Posta
 
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve DecarbonizationUsing IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve DecarbonizationIES VE
 
Meet the new FSP 3000 M-Flex800™
Meet the new FSP 3000 M-Flex800™Meet the new FSP 3000 M-Flex800™
Meet the new FSP 3000 M-Flex800™Adtran
 
Computer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and HazardsComputer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and HazardsSeth Reyes
 
Building Your Own AI Instance (TBLC AI )
Building Your Own AI Instance (TBLC AI )Building Your Own AI Instance (TBLC AI )
Building Your Own AI Instance (TBLC AI )Brian Pichman
 
Machine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdfMachine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdfAijun Zhang
 
AI Fame Rush Review – Virtual Influencer Creation In Just Minutes
AI Fame Rush Review – Virtual Influencer Creation In Just MinutesAI Fame Rush Review – Virtual Influencer Creation In Just Minutes
AI Fame Rush Review – Virtual Influencer Creation In Just MinutesMd Hossain Ali
 
VoIP Service and Marketing using Odoo and Asterisk PBX
VoIP Service and Marketing using Odoo and Asterisk PBXVoIP Service and Marketing using Odoo and Asterisk PBX
VoIP Service and Marketing using Odoo and Asterisk PBXTarek Kalaji
 
Designing A Time bound resource download URL
Designing A Time bound resource download URLDesigning A Time bound resource download URL
Designing A Time bound resource download URLRuncy Oommen
 
How Accurate are Carbon Emissions Projections?
How Accurate are Carbon Emissions Projections?How Accurate are Carbon Emissions Projections?
How Accurate are Carbon Emissions Projections?IES VE
 
Nanopower In Semiconductor Industry.pdf
Nanopower  In Semiconductor Industry.pdfNanopower  In Semiconductor Industry.pdf
Nanopower In Semiconductor Industry.pdfPedro Manuel
 
Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024SkyPlanner
 
OpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability AdventureOpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability AdventureEric D. Schabell
 
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1DianaGray10
 

Dernier (20)

20230104 - machine vision
20230104 - machine vision20230104 - machine vision
20230104 - machine vision
 
Igniting Next Level Productivity with AI-Infused Data Integration Workflows
Igniting Next Level Productivity with AI-Infused Data Integration WorkflowsIgniting Next Level Productivity with AI-Infused Data Integration Workflows
Igniting Next Level Productivity with AI-Infused Data Integration Workflows
 
UiPath Studio Web workshop series - Day 8
UiPath Studio Web workshop series - Day 8UiPath Studio Web workshop series - Day 8
UiPath Studio Web workshop series - Day 8
 
Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)
 
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
 
Comparing Sidecar-less Service Mesh from Cilium and Istio
Comparing Sidecar-less Service Mesh from Cilium and IstioComparing Sidecar-less Service Mesh from Cilium and Istio
Comparing Sidecar-less Service Mesh from Cilium and Istio
 
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve DecarbonizationUsing IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
 
Meet the new FSP 3000 M-Flex800™
Meet the new FSP 3000 M-Flex800™Meet the new FSP 3000 M-Flex800™
Meet the new FSP 3000 M-Flex800™
 
Computer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and HazardsComputer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and Hazards
 
Building Your Own AI Instance (TBLC AI )
Building Your Own AI Instance (TBLC AI )Building Your Own AI Instance (TBLC AI )
Building Your Own AI Instance (TBLC AI )
 
201610817 - edge part1
201610817 - edge part1201610817 - edge part1
201610817 - edge part1
 
Machine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdfMachine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdf
 
AI Fame Rush Review – Virtual Influencer Creation In Just Minutes
AI Fame Rush Review – Virtual Influencer Creation In Just MinutesAI Fame Rush Review – Virtual Influencer Creation In Just Minutes
AI Fame Rush Review – Virtual Influencer Creation In Just Minutes
 
VoIP Service and Marketing using Odoo and Asterisk PBX
VoIP Service and Marketing using Odoo and Asterisk PBXVoIP Service and Marketing using Odoo and Asterisk PBX
VoIP Service and Marketing using Odoo and Asterisk PBX
 
Designing A Time bound resource download URL
Designing A Time bound resource download URLDesigning A Time bound resource download URL
Designing A Time bound resource download URL
 
How Accurate are Carbon Emissions Projections?
How Accurate are Carbon Emissions Projections?How Accurate are Carbon Emissions Projections?
How Accurate are Carbon Emissions Projections?
 
Nanopower In Semiconductor Industry.pdf
Nanopower  In Semiconductor Industry.pdfNanopower  In Semiconductor Industry.pdf
Nanopower In Semiconductor Industry.pdf
 
Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024
 
OpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability AdventureOpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability Adventure
 
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
 

Chef Fundamentals Training Series Module 1: Overview of Chef

  • 3. Nathen Harvey • Technical Community Manager at Opscode • Co-host of the Food Fight Show Podcast • @nathenharvey
  • 5. Multi-week Webinar Series • After completing of this webinar series you will be able to • Automate common infrastructure tasks with Chef • Describe Chef’s architecture • Describe Chef’s various tools • Apply Chef’s primitives to solve your problems
  • 6. How to learn Chef • You bring the domain expertise about your business and problems • Chef provides a framework for solving those problems • Our job is to work together to teach you how to express solutions to your problems with Chef
  • 7. Chef is a Language • Learning Chef is like learning the basics of a language • 80% fluency will be reached very quickly • The remaining 20% just takes practice • The best way to learn Chef is to use Chef
  • 8. Questions & Answers • I’ll post objectives at the beginning of a section • Ask questions in the chat window when they come to you • We’ll answer as many questions as we can at the end of the session • The webinar will be recorded and you’ll be able to watch the recording again.
  • 10. Topics • Overview of Chef • Workstation Setup • Test Node Setup • Dissecting your first Chef run • Introducing the Node object • Writing your first cookbook
  • 11. Topics • Setting attributes, cookbook metadata, templates • Idempotency, notifications, template variables • Roles • Using community cookbooks • Further Resources
  • 13. Lesson Objectives • After completing the lesson, you will be able to • Describe how Chef thinks about Infrastructure Automation • Define the following terms: • Node • Resource • Recipe • Cookbook • Run List • Roles • Search
  • 15. Items of Manipulation (Resources) • Nodes • Networking • Files • Directories • Symlinks • Mounts • Routes • Users • Groups • Packages • Services • Filesystems
  • 16. A tale of growth... Application
  • 19. Application server redundancy App Servers App Databases
  • 20. Add a load balancer App LB App Servers App Databases
  • 22. Now we need a caching layer App LBs App Servers App DB Cache App DBs
  • 23. Infrastructure has a Topology App LBs App Servers App DB Cache App DBs
  • 24. Your Infrastructure is a Snowflake Round Robin DNS App Servers App DB Cache Floating IP? App DBs
  • 25. Complexity Increases Quickly App LBs Cache App Servers DB Cache < Shiny! DB slaves DBs
  • 26. Complexity Increases Quickly App LBs Cache App Servers DB Cache < Shiny! A we re nito mo g?? rin DB slaves DBs
  • 27. Chef Solves This Problem ™ • But you already guessed that, didn’t you?
  • 28. Managing Complexity • Organizations • Environments • Roles • Nodes • Recipes • Cookbooks • Search
  • 30. Organizations • Completely independent tenants of Enterprise Chef • Share nothing with other organizations • May represent different • Companies • Business Units • Departments
  • 32. Environments • Model the life-stages of your applications • Every Organization starts with a single environment • Environments to reflect your patterns and workflow • Development • Test • Staging • Production • etc.
  • 33. Environments Define Policy • Environments may include data attributes necessary for configuring your infrastructure • The URL of your payment service’s API • The location of your package repository • The version of the Chef configuration files that should be used
  • 35. Roles • Roles represent the types of servers in your infrastructure • Load Balancer • Application Server • Database Cache • Database • Monitoring
  • 36. Roles Define Policy • Roles may include a list of Chef configuration files that should be applied. • We call this list a Run List • Roles may include data attributes necessary for configuring your infrastructure • The port that the application server listens on • A list of applications that should be deployed
  • 37. Nodes
  • 38. Nodes • Nodes represent the servers in your infrastructure • Nodes may represent physical servers or virtual servers • Nodes may represent hardware that you own or may represent compute instances in a public or private cloud
  • 39. Node • Each Node will • belong to one Organization • belong to one Environment • have zero or more Roles
  • 40. Nodes Adhere to Policy • An application, the chef-client, runs on each node • chef-client will • gather current system configuration • download the desired system configuration from the Chef server • configure the node such that it adheres to the policy
  • 41. Chef is Infrastructure as Code http://www.flickr.com/photos/louisb/4555295187/ • Programmatically provision and configure components • Treat like any other code base • Reconstruct business from code repository, data backup, and bare metal resources.
  • 42. Configuration Code • Chef ensures each Node complies with the policy • Policy is determined by the configurations included in each Node’s run list • Reduce management complexity through abstraction • Store the configuration of your infrastructure in version control
  • 43. Delcaritive Interface to Resources • You define the policy in your Chef configuration • Your policy states what state each resource should be in, but not how to get there • Chef-client will pull the policy from the Chef Server and enforce the policy on the Node
  • 44. Resources • A Resource represents a piece of the system and its desired state • A package that should be installed • A service that should be running • A file that should be generated • A cron job that should be configured • A user that should be managed • and more
  • 45. Resources in Recipes • Resources are the fundamental building blocks of Chef configuration • Resources are gathered into Recipes • Recipes ensure the system is in the desired state
  • 46. Recipes • Configuration files that describe resources and their desired state • Recipes can: • Install and configure software components • Manage files • Deploy applications • Execute other recipes • and more
  • 47. Recipes package "apache2" template "/etc/apache2/apache2.conf" do source "apache2.conf.erb" owner "root" group "root" mode "0644" variables(:allow_override => "All") notifies :reload, "service[apache2]" end service "apache2" do action [:enable,:start] supports :reload => true end
  • 48. Cookbooks • Recipes are stored in Cookbooks • Cookbooks contain recipes, templates, files, custom resources, etc • Code re-use and modularity http://www.flickr.com/photos/shutterhacks/4474421855/
  • 49. Run List Enterprise Chef What policy sho uld I follow? chef-client Node
  • 50. Run List Enterprise Chef What policy sho uld I follow? chef-client Node “recipe[ntp::client]” “recipe[users]” “role[webserver]”
  • 51. Run List Enterprise Chef What policy sho uld I follow? chef-client “recipe[ntp::client]” “recipe[users]” “role[webserver]”
  • 52. Run Lists Specifies Policy • The Run List is a collection of policies that the Node should follow. • Chef-client obtains the Run List from the Chef Server • Chef-client ensures the Node complies with the policy in the Run List
  • 53. Search • Search for nodes with Roles • Find Topology Data • IP addresses • Hostnames • FQDNs http://www.flickr.com/photos/kathycsus/2686772625
  • 54. So when this... Graphite Nagios Jboss App Memcache Postgres Slaves Postgres Master
  • 56. ...this can happen automatically Graphite Nagios Jboss App Memcache Postgres Slaves Postgres Master
  • 57. Count the Resources Graphite Nagios Jboss App Memcache Postgres Slaves • 12+ resource changes for 1 node addition • • • • • • • • • • • Load balancer config Nagios host ping Nagios host ssh Nagios host HTTP Nagios host app health Graphite CPU Graphite Memory Graphite Disk Graphite SNMP Memcache firewall Postgres firewall Postgres authZ config
  • 58. Manage Complexity • Determine the desired state of your infrastructure • Identify the Resources required to meet that state • Gather the Resources into Recipes • Compose a Run List from Recipes and Roles • Apply a Run List to each Node in your Environment • Your infrastructure adheres to the policy modeled in Chef
  • 59. Configuration Drift • Configuration Drift happens when: • Your infrastructure requirements change • The configuration of a server falls out of policy • Chef makes it easy to manage • Model the new requirements in your Chef configuration files • Run the chef-client to enforce your policies
  • 60. Recap • In today’s webinar, we have • Described how Chef thinks about Infrastructure Automation • Defined the following terms: • Node • Resource • Recipe • Cookbook • Run List • Roles • Search
  • 61. What Questions Do You Have? Nathen Harvey Technical Community Manager, Opscode nharvey@opscode.com @nathenharvey