SlideShare una empresa de Scribd logo
1 de 22
Configuration
Management in
the Cloud
Puppet and Chef
Let’s talk
•
•
•
•
•
•
•

What is Configuration Management
diff cloud.txt physical.txt > painful.out
Why is it painful?
Infrastructure as Code
Puppet
Chef
Examples
What is Configuration
Management
My own definition:
“The art of keeping everything under control”

Wikipedia:
“Configuration management (CM) is a systems
engineering process for establishing and maintaining
consistency of a product‟s performance, functional
and physical attributes with its requirements, design
and operational information throughout its life.”
diff cloud.txt physical.txt
> painful.out
• Physical:
o Resources stay there “forever”
o Attributes / properties are static (ips / hostnames / macaddress)
o Some cases is possible to recover the same system

• Cloud:
o Resources are dynamic and in constant change
“Some times they just disappear, WTF is the cloud it should be always
there”
o Attributes / properties change without notice
o Once a system is done, its done
Why is it painful?
• Config management systems where design for
static/physical environments.
• Most of them use certs/keys based on hostnames.
• With things as “bursting into the cloud” the config
management server that supported 100 servers now
it has to support 1K, 2K 15K servers.
• Most cloud environments cloud instances come
and go.
• In physical environments you don‟t need
completely automation from 0 to app
• Most CMS‟s don‟t have rollbacks.
Infrastructure as Code in
the Cloud
• Keep your CM code in repositories (git/svn)
• Replicate… replicate… replicate…
• The CM system wont do everything by itself
• Have your Dev, Test and Prod environments
• If something fails… destroy and rebuild
• Go Masterless whenever possible
Puppet
• Pros
o Ruby based
o Easy to read and learn
o You can do pretty much anything

• Cons
o Custom changes require you to build specific prividers, resources and the
DSL is not as good as you would like
o Based on certs using hostnames to generate them
o Master/Client communication
o Does not scale very well
Chef
• Pros
o
o
o
o
o

Ruby based
You literally can code in it
You can apply order to the things he will execute
Provides an encrypted way to pass sensitive data
Provides more utilities (knife and search)

• Chef
o
o
o
o

Master server requires more components
Syntax a little bit more complex
You need to learn ruby to get the good out of it
Master/Client communication
Puppet Arch
• Semi Masterless
• Architecture:
Chef Arch
• Master/Client
• Architecture
Puppet Module
• Apache
o Files
• Cert.key
• Ca.key
o Templates
• Vhost.erb
o Manifests
• Init.pp
• Redhat
o Install.pp
o Config.pp
o Postconfig.pp
o Service.pp
Puppet Code – init.pp
• Init.pp
Class apache (
$servername = “myserver”,
$port
= 80,
$serveradmin = “admin@email.com”
){
case @::operatingsystem {
“redhat”, “centos”:
{ require apache::redhat::service }
“ubuntu”:
{ require apache::ubuntu::service }
default:
{ require apache::redhat::service }
}
}
Puppet Code – install.pp
Class apache::redhat::install (
){
package {
“httpd”:
ensure => “latest”;
}
}
Puppet Code – config.pp
Class apache::redhat::config (

$servername
$serveradmin
$serverport

= $apache::servername,
= $apache::serveradmin,
= $apache::serverport

){

require apache::redhat::install

}

file {
“/etc/httpd/conf.d/myvhost.conf”:
owner
=> “apache”,
group
=> “apache”,
content => template(„apache/vhost.erb‟);
}
Puppet Code – service.pp
Class apache::redhat::service (
){
require apache::redhat::config

service {
“httpd”:
ensure => “running”;
}
}
Puppet Masterless
• Create bootstrap script that:
• Download Repository into the Cloud instance
• Create a manifest.pp with the contents of the node
definition
• Call puppet apply -vd -modulepath=/location/modules/ manifest.pp
• Example manifest.pp
import “whatever”
class { “apache”:
servername
=> “myserver.com”,
serveradmin
=> “myemail@gmail.com”,
port
=> 8080
}
Chef Code
• Roles

o Webserver.json

• Cookbooks

o Attributes
• Default.rb
o Files
• Cert.key
• Ca.key
o Templates
• Vhost.erb
o Libraries
o Providers
o Resources
o Recipes
• Default.rb
• install.rb
• Config.rb
• Vhost.rb
{

Chef Roles

"name": ”webserver",
"default_attributes": {
"service": ”httpd”,
“port”: “80”,
"packages": {
"extras": [
”httpd"
]
}
},
"chef_type": "role",
"env_run_lists": {
},
"run_list": [
"recipe[minitest-handler@1.0.6]",
"recipe[basenode@1.0.50]",
"recipe[chef-client@1.1.26]",
"recipe[release_version@8.0.19]",
"recipe[ops@1.0.16]",
"recipe[chef-workstation@1.0.5]”,
“recipe[apache@1.0.1]”
],
"override_attributes": {
},
"description": ”webserver",
"json_class": "Chef::Role"
}
Chef Cookbook Attributes
default['dns']['subdomains']
= ['production', 'test', 'development']
default['dns']['basedomain']
= 'demiops.com.'
default['dns']['route53']['register'] = true
default['dns']['route53']['default_ttl'] = '300'
default['resolver']['options']
= ['rotate', 'attempts:5']
default['resolver']['nameservers']
= ['127.0.0.1']
default[„web‟][„port‟]
= „80‟
default[„web‟][„servername‟] = „myserver.com‟
default[„web‟][„serveradmin‟] = „myemail@gmail.com‟
Chef Cookbook - Recipes
Default.rb
include_recipe “apache::install"
include_recipe ”apache::config"
include_recipe “apache::vhost"
include_recipe ”apache::authorized_keys”

Authorized_keys.rb
cookbook_file "/root/.ssh/authorized_keys" do
group "root"
owner "root"
mode 0600
source "authorized_keys"
end
Chef in the Cloud
• Create a bootstrap script that:
• Download the chef repository into the cloud
instance
• Use minitests to check everything worked
• Install chef-client and knife in the instance
• Use knife to search chef-client inventory and
update dynamically config files
• Use ohai
Questions ?

Más contenido relacionado

La actualidad más candente

Managing Your Cisco Datacenter Network with Ansible
Managing Your Cisco Datacenter Network with AnsibleManaging Your Cisco Datacenter Network with Ansible
Managing Your Cisco Datacenter Network with Ansiblefmaccioni
 
Ansible Automation to Rule Them All
Ansible Automation to Rule Them AllAnsible Automation to Rule Them All
Ansible Automation to Rule Them AllTim Fairweather
 
Ansible Automation Best Practices From Startups to Enterprises - Minnebar 12
Ansible Automation Best Practices From Startups to Enterprises - Minnebar 12Ansible Automation Best Practices From Startups to Enterprises - Minnebar 12
Ansible Automation Best Practices From Startups to Enterprises - Minnebar 12Keith Resar
 
Hosting a Rails App
Hosting a Rails AppHosting a Rails App
Hosting a Rails AppJosh Schramm
 
Go Faster with Ansible (PHP meetup)
Go Faster with Ansible (PHP meetup)Go Faster with Ansible (PHP meetup)
Go Faster with Ansible (PHP meetup)Richard Donkin
 
modern module development - Ken Barber 2012 Edinburgh Puppet Camp
modern module development - Ken Barber 2012 Edinburgh Puppet Campmodern module development - Ken Barber 2012 Edinburgh Puppet Camp
modern module development - Ken Barber 2012 Edinburgh Puppet CampPuppet
 
How Ansible Makes Automation Easy
How Ansible Makes Automation EasyHow Ansible Makes Automation Easy
How Ansible Makes Automation EasyPeter Sankauskas
 
Ansible presentation
Ansible presentationAnsible presentation
Ansible presentationSuresh Kumar
 
Network Automation with Ansible
Network Automation with AnsibleNetwork Automation with Ansible
Network Automation with AnsibleAnas
 
Deploying PHP Applications with Ansible
Deploying PHP Applications with AnsibleDeploying PHP Applications with Ansible
Deploying PHP Applications with AnsibleOrestes Carracedo
 
Ansible 101 - Presentation at Ansible STL Meetup
Ansible 101 - Presentation at Ansible STL MeetupAnsible 101 - Presentation at Ansible STL Meetup
Ansible 101 - Presentation at Ansible STL MeetupJeff Geerling
 
Ansible 2.0 - How to use Ansible to automate your applications in AWS.
Ansible 2.0 - How to use Ansible to automate your applications in AWS.Ansible 2.0 - How to use Ansible to automate your applications in AWS.
Ansible 2.0 - How to use Ansible to automate your applications in AWS.Idan Tohami
 
Ansible v2 and Beyond (Ansible Hawai'i Meetup)
Ansible v2 and Beyond (Ansible Hawai'i Meetup)Ansible v2 and Beyond (Ansible Hawai'i Meetup)
Ansible v2 and Beyond (Ansible Hawai'i Meetup)Timothy Appnel
 
Local Dev on Virtual Machines - Vagrant, VirtualBox and Ansible
Local Dev on Virtual Machines - Vagrant, VirtualBox and AnsibleLocal Dev on Virtual Machines - Vagrant, VirtualBox and Ansible
Local Dev on Virtual Machines - Vagrant, VirtualBox and AnsibleJeff Geerling
 
Ansible Intro - June 2015 / Ansible Barcelona User Group
Ansible Intro - June 2015 / Ansible Barcelona User GroupAnsible Intro - June 2015 / Ansible Barcelona User Group
Ansible Intro - June 2015 / Ansible Barcelona User GroupOrestes Carracedo
 
Ansible on aws - Pop-up Loft Tel Aviv
Ansible on aws - Pop-up Loft Tel AvivAnsible on aws - Pop-up Loft Tel Aviv
Ansible on aws - Pop-up Loft Tel AvivAmazon Web Services
 
Automated Deployment and Configuration Engines. Ansible
Automated Deployment and Configuration Engines. AnsibleAutomated Deployment and Configuration Engines. Ansible
Automated Deployment and Configuration Engines. AnsibleAlberto Molina Coballes
 
Fake IT, until you make IT
Fake IT, until you make ITFake IT, until you make IT
Fake IT, until you make ITBas Meijer
 

La actualidad más candente (20)

Managing Your Cisco Datacenter Network with Ansible
Managing Your Cisco Datacenter Network with AnsibleManaging Your Cisco Datacenter Network with Ansible
Managing Your Cisco Datacenter Network with Ansible
 
Ansible Automation to Rule Them All
Ansible Automation to Rule Them AllAnsible Automation to Rule Them All
Ansible Automation to Rule Them All
 
Ansible Automation Best Practices From Startups to Enterprises - Minnebar 12
Ansible Automation Best Practices From Startups to Enterprises - Minnebar 12Ansible Automation Best Practices From Startups to Enterprises - Minnebar 12
Ansible Automation Best Practices From Startups to Enterprises - Minnebar 12
 
Hosting a Rails App
Hosting a Rails AppHosting a Rails App
Hosting a Rails App
 
Ansible Case Studies
Ansible Case StudiesAnsible Case Studies
Ansible Case Studies
 
Go Faster with Ansible (PHP meetup)
Go Faster with Ansible (PHP meetup)Go Faster with Ansible (PHP meetup)
Go Faster with Ansible (PHP meetup)
 
modern module development - Ken Barber 2012 Edinburgh Puppet Camp
modern module development - Ken Barber 2012 Edinburgh Puppet Campmodern module development - Ken Barber 2012 Edinburgh Puppet Camp
modern module development - Ken Barber 2012 Edinburgh Puppet Camp
 
How Ansible Makes Automation Easy
How Ansible Makes Automation EasyHow Ansible Makes Automation Easy
How Ansible Makes Automation Easy
 
Ansible presentation
Ansible presentationAnsible presentation
Ansible presentation
 
Network Automation with Ansible
Network Automation with AnsibleNetwork Automation with Ansible
Network Automation with Ansible
 
Deploying PHP Applications with Ansible
Deploying PHP Applications with AnsibleDeploying PHP Applications with Ansible
Deploying PHP Applications with Ansible
 
Ansible
AnsibleAnsible
Ansible
 
Ansible 101 - Presentation at Ansible STL Meetup
Ansible 101 - Presentation at Ansible STL MeetupAnsible 101 - Presentation at Ansible STL Meetup
Ansible 101 - Presentation at Ansible STL Meetup
 
Ansible 2.0 - How to use Ansible to automate your applications in AWS.
Ansible 2.0 - How to use Ansible to automate your applications in AWS.Ansible 2.0 - How to use Ansible to automate your applications in AWS.
Ansible 2.0 - How to use Ansible to automate your applications in AWS.
 
Ansible v2 and Beyond (Ansible Hawai'i Meetup)
Ansible v2 and Beyond (Ansible Hawai'i Meetup)Ansible v2 and Beyond (Ansible Hawai'i Meetup)
Ansible v2 and Beyond (Ansible Hawai'i Meetup)
 
Local Dev on Virtual Machines - Vagrant, VirtualBox and Ansible
Local Dev on Virtual Machines - Vagrant, VirtualBox and AnsibleLocal Dev on Virtual Machines - Vagrant, VirtualBox and Ansible
Local Dev on Virtual Machines - Vagrant, VirtualBox and Ansible
 
Ansible Intro - June 2015 / Ansible Barcelona User Group
Ansible Intro - June 2015 / Ansible Barcelona User GroupAnsible Intro - June 2015 / Ansible Barcelona User Group
Ansible Intro - June 2015 / Ansible Barcelona User Group
 
Ansible on aws - Pop-up Loft Tel Aviv
Ansible on aws - Pop-up Loft Tel AvivAnsible on aws - Pop-up Loft Tel Aviv
Ansible on aws - Pop-up Loft Tel Aviv
 
Automated Deployment and Configuration Engines. Ansible
Automated Deployment and Configuration Engines. AnsibleAutomated Deployment and Configuration Engines. Ansible
Automated Deployment and Configuration Engines. Ansible
 
Fake IT, until you make IT
Fake IT, until you make ITFake IT, until you make IT
Fake IT, until you make IT
 

Destacado

Financial Management with ServiceNow at Franke
Financial Management with ServiceNow at FrankeFinancial Management with ServiceNow at Franke
Financial Management with ServiceNow at FrankeAspediens
 
System Center + Cireson vs. ServiceNow
System Center + Cireson vs. ServiceNowSystem Center + Cireson vs. ServiceNow
System Center + Cireson vs. ServiceNowCireson
 
HGConcept-ITOM-Service Centric Operations
HGConcept-ITOM-Service Centric OperationsHGConcept-ITOM-Service Centric Operations
HGConcept-ITOM-Service Centric OperationsHGConcept Inc.
 
Openstack - Enterprise cloud management platform
Openstack - Enterprise cloud management platformOpenstack - Enterprise cloud management platform
Openstack - Enterprise cloud management platformNagaraj Shenoy
 
The Service-Oriented Enterprise with ServiceNow
The Service-Oriented Enterprise with ServiceNowThe Service-Oriented Enterprise with ServiceNow
The Service-Oriented Enterprise with ServiceNowAspediens
 
Using Chef for Automated Infrastructure in the Cloud
Using Chef for Automated Infrastructure in the CloudUsing Chef for Automated Infrastructure in the Cloud
Using Chef for Automated Infrastructure in the CloudJesse Robbins
 
Zenoss & ServiceNow Integration - Incident Management & CMDB
Zenoss & ServiceNow Integration - Incident Management & CMDBZenoss & ServiceNow Integration - Incident Management & CMDB
Zenoss & ServiceNow Integration - Incident Management & CMDBZenoss
 
Presentation cloud management platform
Presentation   cloud management platformPresentation   cloud management platform
Presentation cloud management platformxKinAnx
 
Chef - Configuration Management for the Cloud
Chef - Configuration Management for the CloudChef - Configuration Management for the Cloud
Chef - Configuration Management for the CloudJames Casey
 
RHTE2015_CloudForms_OpenStack
RHTE2015_CloudForms_OpenStackRHTE2015_CloudForms_OpenStack
RHTE2015_CloudForms_OpenStackJerome Marc
 
Openstack Cloud Management and Automation Using Red Hat Cloudforms 4.0
Openstack Cloud  Management and Automation Using Red Hat Cloudforms 4.0Openstack Cloud  Management and Automation Using Red Hat Cloudforms 4.0
Openstack Cloud Management and Automation Using Red Hat Cloudforms 4.0Prasad Mukhedkar
 

Destacado (13)

Financial Management with ServiceNow at Franke
Financial Management with ServiceNow at FrankeFinancial Management with ServiceNow at Franke
Financial Management with ServiceNow at Franke
 
System Center + Cireson vs. ServiceNow
System Center + Cireson vs. ServiceNowSystem Center + Cireson vs. ServiceNow
System Center + Cireson vs. ServiceNow
 
HGConcept-ITOM-Service Centric Operations
HGConcept-ITOM-Service Centric OperationsHGConcept-ITOM-Service Centric Operations
HGConcept-ITOM-Service Centric Operations
 
Openstack - Enterprise cloud management platform
Openstack - Enterprise cloud management platformOpenstack - Enterprise cloud management platform
Openstack - Enterprise cloud management platform
 
The Service-Oriented Enterprise with ServiceNow
The Service-Oriented Enterprise with ServiceNowThe Service-Oriented Enterprise with ServiceNow
The Service-Oriented Enterprise with ServiceNow
 
Using Chef for Automated Infrastructure in the Cloud
Using Chef for Automated Infrastructure in the CloudUsing Chef for Automated Infrastructure in the Cloud
Using Chef for Automated Infrastructure in the Cloud
 
Zenoss & ServiceNow Integration - Incident Management & CMDB
Zenoss & ServiceNow Integration - Incident Management & CMDBZenoss & ServiceNow Integration - Incident Management & CMDB
Zenoss & ServiceNow Integration - Incident Management & CMDB
 
Presentation cloud management platform
Presentation   cloud management platformPresentation   cloud management platform
Presentation cloud management platform
 
Chef - Configuration Management for the Cloud
Chef - Configuration Management for the CloudChef - Configuration Management for the Cloud
Chef - Configuration Management for the Cloud
 
RHTE2015_CloudForms_OpenStack
RHTE2015_CloudForms_OpenStackRHTE2015_CloudForms_OpenStack
RHTE2015_CloudForms_OpenStack
 
Cloudforms Workshop
Cloudforms WorkshopCloudforms Workshop
Cloudforms Workshop
 
Openstack Cloud Management and Automation Using Red Hat Cloudforms 4.0
Openstack Cloud  Management and Automation Using Red Hat Cloudforms 4.0Openstack Cloud  Management and Automation Using Red Hat Cloudforms 4.0
Openstack Cloud Management and Automation Using Red Hat Cloudforms 4.0
 
Cloud Management with vRealize Operations
Cloud Management with vRealize OperationsCloud Management with vRealize Operations
Cloud Management with vRealize Operations
 

Similar a Configuration Management in the Cloud - Cloud Phoenix Meetup Feb 2014

20100425 Configuration Management With Puppet Lfnw
20100425 Configuration Management With Puppet Lfnw20100425 Configuration Management With Puppet Lfnw
20100425 Configuration Management With Puppet Lfnwgarrett honeycutt
 
Agiles Peru 2019 - Infrastructure As Code
Agiles Peru 2019 - Infrastructure As CodeAgiles Peru 2019 - Infrastructure As Code
Agiles Peru 2019 - Infrastructure As CodeMario IC
 
Introduction to Chef - April 22 2015
Introduction to Chef - April 22 2015Introduction to Chef - April 22 2015
Introduction to Chef - April 22 2015Jennifer Davis
 
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto Docker, Inc.
 
Automating Complex Setups with Puppet
Automating Complex Setups with PuppetAutomating Complex Setups with Puppet
Automating Complex Setups with PuppetKris Buytaert
 
Stress Free Deployment - Confoo 2011
Stress Free Deployment  - Confoo 2011Stress Free Deployment  - Confoo 2011
Stress Free Deployment - Confoo 2011Bachkoutou Toutou
 
20090514 Introducing Puppet To Sasag
20090514 Introducing Puppet To Sasag20090514 Introducing Puppet To Sasag
20090514 Introducing Puppet To Sasaggarrett honeycutt
 
Yapc10 Cdt World Domination
Yapc10   Cdt World DominationYapc10   Cdt World Domination
Yapc10 Cdt World DominationcPanel
 
Using Puppet in Small Infrastructures
Using Puppet in Small InfrastructuresUsing Puppet in Small Infrastructures
Using Puppet in Small InfrastructuresRachel Andrew
 
Can puppet help you run docker on a T2.Micro?
Can puppet help you run docker on a T2.Micro?Can puppet help you run docker on a T2.Micro?
Can puppet help you run docker on a T2.Micro?Neil Millard
 
Introduction to Chef - Techsuperwomen Summit
Introduction to Chef - Techsuperwomen SummitIntroduction to Chef - Techsuperwomen Summit
Introduction to Chef - Techsuperwomen SummitJennifer Davis
 
CouchDB for Web Applications - Erlang Factory London 2009
CouchDB for Web Applications - Erlang Factory London 2009CouchDB for Web Applications - Erlang Factory London 2009
CouchDB for Web Applications - Erlang Factory London 2009Jason Davies
 
EC2 AMI Factory with Chef, Berkshelf, and Packer
EC2 AMI Factory with Chef, Berkshelf, and PackerEC2 AMI Factory with Chef, Berkshelf, and Packer
EC2 AMI Factory with Chef, Berkshelf, and PackerGeorge Miranda
 
Introduction to Ansible
Introduction to AnsibleIntroduction to Ansible
Introduction to AnsibleMichael Bahr
 
Our Puppet Story (Linuxtag 2014)
Our Puppet Story (Linuxtag 2014)Our Puppet Story (Linuxtag 2014)
Our Puppet Story (Linuxtag 2014)DECK36
 
V mware
V mwareV mware
V mwaredvmug1
 
Puppet Primer, Robbie Jerrom, Solution Architect VMware
Puppet Primer, Robbie Jerrom, Solution Architect VMwarePuppet Primer, Robbie Jerrom, Solution Architect VMware
Puppet Primer, Robbie Jerrom, Solution Architect VMwaresubtitle
 
The Docker "Gauntlet" - Introduction, Ecosystem, Deployment, Orchestration
The Docker "Gauntlet" - Introduction, Ecosystem, Deployment, OrchestrationThe Docker "Gauntlet" - Introduction, Ecosystem, Deployment, Orchestration
The Docker "Gauntlet" - Introduction, Ecosystem, Deployment, OrchestrationErica Windisch
 
Introduction to Chef
Introduction to ChefIntroduction to Chef
Introduction to Chefkevsmith
 

Similar a Configuration Management in the Cloud - Cloud Phoenix Meetup Feb 2014 (20)

20100425 Configuration Management With Puppet Lfnw
20100425 Configuration Management With Puppet Lfnw20100425 Configuration Management With Puppet Lfnw
20100425 Configuration Management With Puppet Lfnw
 
Agiles Peru 2019 - Infrastructure As Code
Agiles Peru 2019 - Infrastructure As CodeAgiles Peru 2019 - Infrastructure As Code
Agiles Peru 2019 - Infrastructure As Code
 
Introduction to Chef - April 22 2015
Introduction to Chef - April 22 2015Introduction to Chef - April 22 2015
Introduction to Chef - April 22 2015
 
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto
 
Automating Complex Setups with Puppet
Automating Complex Setups with PuppetAutomating Complex Setups with Puppet
Automating Complex Setups with Puppet
 
Stress Free Deployment - Confoo 2011
Stress Free Deployment  - Confoo 2011Stress Free Deployment  - Confoo 2011
Stress Free Deployment - Confoo 2011
 
20090514 Introducing Puppet To Sasag
20090514 Introducing Puppet To Sasag20090514 Introducing Puppet To Sasag
20090514 Introducing Puppet To Sasag
 
Yapc10 Cdt World Domination
Yapc10   Cdt World DominationYapc10   Cdt World Domination
Yapc10 Cdt World Domination
 
Using Puppet in Small Infrastructures
Using Puppet in Small InfrastructuresUsing Puppet in Small Infrastructures
Using Puppet in Small Infrastructures
 
Can puppet help you run docker on a T2.Micro?
Can puppet help you run docker on a T2.Micro?Can puppet help you run docker on a T2.Micro?
Can puppet help you run docker on a T2.Micro?
 
Introduction to Chef - Techsuperwomen Summit
Introduction to Chef - Techsuperwomen SummitIntroduction to Chef - Techsuperwomen Summit
Introduction to Chef - Techsuperwomen Summit
 
Top ten-list
Top ten-listTop ten-list
Top ten-list
 
CouchDB for Web Applications - Erlang Factory London 2009
CouchDB for Web Applications - Erlang Factory London 2009CouchDB for Web Applications - Erlang Factory London 2009
CouchDB for Web Applications - Erlang Factory London 2009
 
EC2 AMI Factory with Chef, Berkshelf, and Packer
EC2 AMI Factory with Chef, Berkshelf, and PackerEC2 AMI Factory with Chef, Berkshelf, and Packer
EC2 AMI Factory with Chef, Berkshelf, and Packer
 
Introduction to Ansible
Introduction to AnsibleIntroduction to Ansible
Introduction to Ansible
 
Our Puppet Story (Linuxtag 2014)
Our Puppet Story (Linuxtag 2014)Our Puppet Story (Linuxtag 2014)
Our Puppet Story (Linuxtag 2014)
 
V mware
V mwareV mware
V mware
 
Puppet Primer, Robbie Jerrom, Solution Architect VMware
Puppet Primer, Robbie Jerrom, Solution Architect VMwarePuppet Primer, Robbie Jerrom, Solution Architect VMware
Puppet Primer, Robbie Jerrom, Solution Architect VMware
 
The Docker "Gauntlet" - Introduction, Ecosystem, Deployment, Orchestration
The Docker "Gauntlet" - Introduction, Ecosystem, Deployment, OrchestrationThe Docker "Gauntlet" - Introduction, Ecosystem, Deployment, Orchestration
The Docker "Gauntlet" - Introduction, Ecosystem, Deployment, Orchestration
 
Introduction to Chef
Introduction to ChefIntroduction to Chef
Introduction to Chef
 

Más de Miguel Zuniga

Implementing open source as your business model
Implementing open source as your business modelImplementing open source as your business model
Implementing open source as your business modelMiguel Zuniga
 
Openstack components as containerized microservices
Openstack components as containerized microservicesOpenstack components as containerized microservices
Openstack components as containerized microservicesMiguel Zuniga
 
Creating hybrid cloud openstack + public cloud
Creating hybrid cloud   openstack + public cloudCreating hybrid cloud   openstack + public cloud
Creating hybrid cloud openstack + public cloudMiguel Zuniga
 
Platform as a Service with Kubernetes and Mesos
Platform as a Service with Kubernetes and Mesos Platform as a Service with Kubernetes and Mesos
Platform as a Service with Kubernetes and Mesos Miguel Zuniga
 
Continuous Integration with Puppet
Continuous Integration with PuppetContinuous Integration with Puppet
Continuous Integration with PuppetMiguel Zuniga
 
Cloud Platform Symantec Meetup Nov 2014
Cloud Platform Symantec Meetup Nov 2014Cloud Platform Symantec Meetup Nov 2014
Cloud Platform Symantec Meetup Nov 2014Miguel Zuniga
 
Managing and Scaling Puppet - PuppetConf 2014
Managing and Scaling Puppet - PuppetConf 2014Managing and Scaling Puppet - PuppetConf 2014
Managing and Scaling Puppet - PuppetConf 2014Miguel Zuniga
 
Fluo CICD OpenStack Summit
Fluo CICD OpenStack SummitFluo CICD OpenStack Summit
Fluo CICD OpenStack SummitMiguel Zuniga
 
Private cloud cloud-phoenix-april-2014
Private cloud cloud-phoenix-april-2014Private cloud cloud-phoenix-april-2014
Private cloud cloud-phoenix-april-2014Miguel Zuniga
 
Containers - Cloud Phoenix March Meetup
Containers - Cloud Phoenix March MeetupContainers - Cloud Phoenix March Meetup
Containers - Cloud Phoenix March MeetupMiguel Zuniga
 
Open escalar presentation
Open escalar presentationOpen escalar presentation
Open escalar presentationMiguel Zuniga
 

Más de Miguel Zuniga (11)

Implementing open source as your business model
Implementing open source as your business modelImplementing open source as your business model
Implementing open source as your business model
 
Openstack components as containerized microservices
Openstack components as containerized microservicesOpenstack components as containerized microservices
Openstack components as containerized microservices
 
Creating hybrid cloud openstack + public cloud
Creating hybrid cloud   openstack + public cloudCreating hybrid cloud   openstack + public cloud
Creating hybrid cloud openstack + public cloud
 
Platform as a Service with Kubernetes and Mesos
Platform as a Service with Kubernetes and Mesos Platform as a Service with Kubernetes and Mesos
Platform as a Service with Kubernetes and Mesos
 
Continuous Integration with Puppet
Continuous Integration with PuppetContinuous Integration with Puppet
Continuous Integration with Puppet
 
Cloud Platform Symantec Meetup Nov 2014
Cloud Platform Symantec Meetup Nov 2014Cloud Platform Symantec Meetup Nov 2014
Cloud Platform Symantec Meetup Nov 2014
 
Managing and Scaling Puppet - PuppetConf 2014
Managing and Scaling Puppet - PuppetConf 2014Managing and Scaling Puppet - PuppetConf 2014
Managing and Scaling Puppet - PuppetConf 2014
 
Fluo CICD OpenStack Summit
Fluo CICD OpenStack SummitFluo CICD OpenStack Summit
Fluo CICD OpenStack Summit
 
Private cloud cloud-phoenix-april-2014
Private cloud cloud-phoenix-april-2014Private cloud cloud-phoenix-april-2014
Private cloud cloud-phoenix-april-2014
 
Containers - Cloud Phoenix March Meetup
Containers - Cloud Phoenix March MeetupContainers - Cloud Phoenix March Meetup
Containers - Cloud Phoenix March Meetup
 
Open escalar presentation
Open escalar presentationOpen escalar presentation
Open escalar presentation
 

Último

SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGSujit Pal
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 

Último (20)

SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAG
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 

Configuration Management in the Cloud - Cloud Phoenix Meetup Feb 2014

  • 2. Let’s talk • • • • • • • What is Configuration Management diff cloud.txt physical.txt > painful.out Why is it painful? Infrastructure as Code Puppet Chef Examples
  • 3. What is Configuration Management My own definition: “The art of keeping everything under control” Wikipedia: “Configuration management (CM) is a systems engineering process for establishing and maintaining consistency of a product‟s performance, functional and physical attributes with its requirements, design and operational information throughout its life.”
  • 4. diff cloud.txt physical.txt > painful.out • Physical: o Resources stay there “forever” o Attributes / properties are static (ips / hostnames / macaddress) o Some cases is possible to recover the same system • Cloud: o Resources are dynamic and in constant change “Some times they just disappear, WTF is the cloud it should be always there” o Attributes / properties change without notice o Once a system is done, its done
  • 5. Why is it painful? • Config management systems where design for static/physical environments. • Most of them use certs/keys based on hostnames. • With things as “bursting into the cloud” the config management server that supported 100 servers now it has to support 1K, 2K 15K servers. • Most cloud environments cloud instances come and go. • In physical environments you don‟t need completely automation from 0 to app • Most CMS‟s don‟t have rollbacks.
  • 6. Infrastructure as Code in the Cloud • Keep your CM code in repositories (git/svn) • Replicate… replicate… replicate… • The CM system wont do everything by itself • Have your Dev, Test and Prod environments • If something fails… destroy and rebuild • Go Masterless whenever possible
  • 7. Puppet • Pros o Ruby based o Easy to read and learn o You can do pretty much anything • Cons o Custom changes require you to build specific prividers, resources and the DSL is not as good as you would like o Based on certs using hostnames to generate them o Master/Client communication o Does not scale very well
  • 8. Chef • Pros o o o o o Ruby based You literally can code in it You can apply order to the things he will execute Provides an encrypted way to pass sensitive data Provides more utilities (knife and search) • Chef o o o o Master server requires more components Syntax a little bit more complex You need to learn ruby to get the good out of it Master/Client communication
  • 9. Puppet Arch • Semi Masterless • Architecture:
  • 11. Puppet Module • Apache o Files • Cert.key • Ca.key o Templates • Vhost.erb o Manifests • Init.pp • Redhat o Install.pp o Config.pp o Postconfig.pp o Service.pp
  • 12. Puppet Code – init.pp • Init.pp Class apache ( $servername = “myserver”, $port = 80, $serveradmin = “admin@email.com” ){ case @::operatingsystem { “redhat”, “centos”: { require apache::redhat::service } “ubuntu”: { require apache::ubuntu::service } default: { require apache::redhat::service } } }
  • 13. Puppet Code – install.pp Class apache::redhat::install ( ){ package { “httpd”: ensure => “latest”; } }
  • 14. Puppet Code – config.pp Class apache::redhat::config ( $servername $serveradmin $serverport = $apache::servername, = $apache::serveradmin, = $apache::serverport ){ require apache::redhat::install } file { “/etc/httpd/conf.d/myvhost.conf”: owner => “apache”, group => “apache”, content => template(„apache/vhost.erb‟); }
  • 15. Puppet Code – service.pp Class apache::redhat::service ( ){ require apache::redhat::config service { “httpd”: ensure => “running”; } }
  • 16. Puppet Masterless • Create bootstrap script that: • Download Repository into the Cloud instance • Create a manifest.pp with the contents of the node definition • Call puppet apply -vd -modulepath=/location/modules/ manifest.pp • Example manifest.pp import “whatever” class { “apache”: servername => “myserver.com”, serveradmin => “myemail@gmail.com”, port => 8080 }
  • 17. Chef Code • Roles o Webserver.json • Cookbooks o Attributes • Default.rb o Files • Cert.key • Ca.key o Templates • Vhost.erb o Libraries o Providers o Resources o Recipes • Default.rb • install.rb • Config.rb • Vhost.rb
  • 18. { Chef Roles "name": ”webserver", "default_attributes": { "service": ”httpd”, “port”: “80”, "packages": { "extras": [ ”httpd" ] } }, "chef_type": "role", "env_run_lists": { }, "run_list": [ "recipe[minitest-handler@1.0.6]", "recipe[basenode@1.0.50]", "recipe[chef-client@1.1.26]", "recipe[release_version@8.0.19]", "recipe[ops@1.0.16]", "recipe[chef-workstation@1.0.5]”, “recipe[apache@1.0.1]” ], "override_attributes": { }, "description": ”webserver", "json_class": "Chef::Role" }
  • 19. Chef Cookbook Attributes default['dns']['subdomains'] = ['production', 'test', 'development'] default['dns']['basedomain'] = 'demiops.com.' default['dns']['route53']['register'] = true default['dns']['route53']['default_ttl'] = '300' default['resolver']['options'] = ['rotate', 'attempts:5'] default['resolver']['nameservers'] = ['127.0.0.1'] default[„web‟][„port‟] = „80‟ default[„web‟][„servername‟] = „myserver.com‟ default[„web‟][„serveradmin‟] = „myemail@gmail.com‟
  • 20. Chef Cookbook - Recipes Default.rb include_recipe “apache::install" include_recipe ”apache::config" include_recipe “apache::vhost" include_recipe ”apache::authorized_keys” Authorized_keys.rb cookbook_file "/root/.ssh/authorized_keys" do group "root" owner "root" mode 0600 source "authorized_keys" end
  • 21. Chef in the Cloud • Create a bootstrap script that: • Download the chef repository into the cloud instance • Use minitests to check everything worked • Install chef-client and knife in the instance • Use knife to search chef-client inventory and update dynamically config files • Use ohai