Your SlideShare is downloading. ×
0
Under The Covers - Chef in 20 Minutes      www.opscode.com
Congratulations!!!          • You have a                 Cloud          • Now what?          http://www.flickr.com/photos/i...
APIs are awesome            • You can provision              compute resources in              seconds            • You ca...
Chef can help with that• knife ec2 server                            • knife brightbox        create                      ...
But then what?http://www.flickr.com/photos/doctorow/2698336843
You need to configure themGive me some operating system and put it on the network
Chef can help with that too              • That’s what we do.
Golden Images are not the answer•   Gold is heavy•   Hard to transport•   Hard to mold•   Easy to lose    configuration de...
Chef is Infrastructure as Code               •     Programmatically                     provision and configure           ...
Chef configures Resources•   Nodes•   Networking•   Files•   Directories•   Symlinks•   Mounts•   Routes•   Users and Grou...
With declarative interfaces             •     Define policy             •     Say what, not how             •     Pull not...
That looks like thispackage "ntp" do  action :installend              template "/etc/ntp.conf" do                source "n...
That looks like thispackage "net-snmp" do  action :installend              template "/etc/snmpd.conf" do                so...
Creating recipes and cookbooks•   Recipes are collections of    Resources•   Cookbooks contain recipes,    Templates, file...
Apply Run Lists to Nodes                      Server                        Server                     chef-server        ...
Build up reusable code                      Server                        Server                     chef-server          ...
Apply them in order                      Server                        Server                     chef-server             ...
Roles         Server           Server        chef-server         Server           Server                                  ...
Roles Server   Serverchef-server Server   Server                                                       chef-client        ...
Roles Server   Serverchef-server Server   Server                                ntp                                       ...
Recipes can search chef-sever                 •      Search for nodes with                        Roles                 • ...
And stitch together Infrastructures      App LBs                     App Servers      App DB Cache      App DBs
Your Infrastructure is a snow flake       App LBs                     App Servers      App DB Cache   Floating IP?      Ap...
And it Evolves        App LBs              Cache                   App ServersNoSQL         DB Cache              DB slave...
Quickly      DC2DC1            DC3
Build anything       • Simple internal applications       • Complex internal applications       • Workstations       • Had...
And manage it simply• Automatically reconfigure    everything• Load balancers• Metrics collection    systems• Monitoring s...
Questions?          sarah.novotny@gmail.com              www.opscode.comslides and original talk concept - Sean O’Meara
under the covers -- chef in 20 minutes or less
Upcoming SlideShare
Loading in...5
×

under the covers -- chef in 20 minutes or less

1,447

Published on

Learn how to automate your infrastructure to make more time for fun things. In this rapid fire intro to Chef, an open source provisioning and automation platform, we'll touch on the strengths of it's flexible architecture as well as showing some concrete and simple starting points on your path to become an executive chef.

Published in: Technology, Self Improvement
0 Comments
2 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
1,447
On Slideshare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
18
Comments
0
Likes
2
Embeds 0
No embeds

No notes for slide

Transcript of "under the covers -- chef in 20 minutes or less"

  1. 1. Under The Covers - Chef in 20 Minutes www.opscode.com
  2. 2. Congratulations!!! • You have a Cloud • Now what? http://www.flickr.com/photos/ian_munroe/4758240536/
  3. 3. APIs are awesome • You can provision compute resources in seconds • You can provision storage resources in seconds • That’s cool. http://www.flickr.com/photos/jdhancock/3634246981/Give me some operating system and put it on the network
  4. 4. Chef can help with that• knife ec2 server • knife brightbox create server create• knife rackspace • knife vsphere server create server create• knife terremark • knife openstack server create server create• knife gandi • knife eucalyptus server create server create• knife bluebox server createhttp://www.flickr.com/photos/kyz/3122499444/
  5. 5. But then what?http://www.flickr.com/photos/doctorow/2698336843
  6. 6. You need to configure themGive me some operating system and put it on the network
  7. 7. Chef can help with that too • That’s what we do.
  8. 8. Golden Images are not the answer• Gold is heavy• Hard to transport• Hard to mold• Easy to lose configuration detailhttp://www.flickr.com/photos/bankofengland/5762003476
  9. 9. Chef is Infrastructure as Code • Programmatically provision and configure • Treat like any other code base • Reconstruct operations from code repository, data backup, and bare metal resources. http://www.flickr.com/photos/louisb/4555295187/
  10. 10. Chef configures Resources• Nodes• Networking• Files• Directories• Symlinks• Mounts• Routes• Users and Groups• Tasks• Packages• Software• Services• Configurations• Stuff http://www.flickr.com/photos/stevekeys/3123167585/
  11. 11. With declarative interfaces • Define policy • Say what, not how • Pull not Push http://www.flickr.com/photos/bixentro/2591838509/
  12. 12. That looks like thispackage "ntp" do action :installend template "/etc/ntp.conf" do source "ntp.conf.erb" owner "root" group "root" mode 0644 action :create variables( :ntp_server => “time.example.com”) notifies :restart, “service[ntpd]” end service "ntpd" do action [:enable,:start] end
  13. 13. That looks like thispackage "net-snmp" do action :installend template "/etc/snmpd.conf" do source "snmpd.conf.erb" owner "root" group "root" mode 0644 action :create variables( :community_string => “not_public”) notifies :restart, “service[snmpd]” end service "snmpd" do action [:enable,:start] end
  14. 14. Creating recipes and cookbooks• Recipes are collections of Resources• Cookbooks contain recipes, Templates, files, custom resources, etc• Code re-use and modularity http://www.flickr.com/photos/shutterhacks/4474421855/
  15. 15. Apply Run Lists to Nodes Server Server chef-server Server Server Ohai! API chef-client Give me recipe[ntp::client] ntp node client.rbexecuted in order!
  16. 16. Build up reusable code Server Server chef-server Server Server Ohai! chef-client API Give me “ntp::client”, ntp “openssh::server” openssh node client.rb server.rbexecuted in order!
  17. 17. Apply them in order Server Server chef-server Server Server Ohai! chef-client Give me API “recipe[ntp::client]”, ntp “recipe[openssh::server]”, “recipe[apache]”, openssh node “recipe[php]” client.rb apache server.rb php default.rb default.rbexecuted in order!
  18. 18. Roles Server Server chef-server Server Server Role Recipe API Role Role Recipe Role Recipe RecipeKnife Recipe Recipe Recipe
  19. 19. Roles Server Serverchef-server Server Server chef-client Ohai! API Give me ntp “role[base]”, “role[webserver]” openssh node client.rb apache server.rb php default.rb default.rb
  20. 20. Roles Server Serverchef-server Server Server ntp openssh chef-client API client.rb apache php server.rb “role[webserver]” default.rb ntp default.rb node openssh chef-client client.rb mysql server.rb server.rb “role[database]” node
  21. 21. Recipes can search chef-sever • Search for nodes with Roles • Find configuration data • IP addresses • Hostnames • FQDNs http://www.flickr.com/photos/fotos_medem/3399096196/
  22. 22. And stitch together Infrastructures App LBs App Servers App DB Cache App DBs
  23. 23. Your Infrastructure is a snow flake App LBs App Servers App DB Cache Floating IP? App DBs
  24. 24. And it Evolves App LBs Cache App ServersNoSQL DB Cache DB slaves DBs
  25. 25. Quickly DC2DC1 DC3
  26. 26. Build anything • Simple internal applications • Complex internal applications • Workstations • Hadoop clusters • IaaS applications • PaaS applications • SaaS applications • Storage systems • You name ithttp://www.flickr.com/photos/hyku/245010680/
  27. 27. And manage it simply• Automatically reconfigure everything• Load balancers• Metrics collection systems• Monitoring systems• Cloud migrations become trivialhttp://www.flickr.com/photos/helico/404640681/
  28. 28. Questions? sarah.novotny@gmail.com www.opscode.comslides and original talk concept - Sean O’Meara
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×