Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Chef introduction
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Wojciech Wnętrzak
December 05, 2011
Programming
6
350
Chef introduction
Presentation about
http://www.opscode.com/chef/
Wojciech Wnętrzak
December 05, 2011
Tweet
Share
More Decks by Wojciech Wnętrzak
See All by Wojciech Wnętrzak
Kamal - pierwsze produkcyjne wrażenia
morgoth
0
31
Other Decks in Programming
See All in Programming
オブザーバビリティ駆動開発って実際どうなの?
yohfee
3
740
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
290
ふつうの Rubyist、ちいさなデバイス、大きな一年
bash0c7
0
700
AI主導でFastAPIのWebサービスを作るときに 人間が構造化すべき境界線
okajun35
0
610
RubyとGoでゼロから作る証券システム: 高信頼性が求められるシステムのコードの外側にある設計と運用のリアル
free_world21
0
220
New in Go 1.26 Implementing go fix in product development
sunecosuri
0
370
Unity6.3 AudioUpdate
cova8bitdots
0
110
どんと来い、データベース信頼性エンジニアリング / Introduction to DBRE
nnaka2992
1
230
文字コードの話
qnighy
44
17k
Go1.26 go fixをプロダクトに適用して困ったこと
kurakura0916
0
330
TROCCOで実現するkintone+BigQueryによるオペレーション改善
ssxota
0
140
「やめとこ」がなくなった — 1月にZennを始めて22本書いた AI共創開発のリアル
atani14
0
360
Featured
See All Featured
Practical Orchestrator
shlominoach
191
11k
Groundhog Day: Seeking Process in Gaming for Health
codingconduct
0
110
AI Search: Implications for SEO and How to Move Forward - #ShenzhenSEOConference
aleyda
1
1.1k
Building Applications with DynamoDB
mza
96
6.9k
The agentic SEO stack - context over prompts
schlessera
0
680
Measuring & Analyzing Core Web Vitals
bluesmoon
9
770
Optimizing for Happiness
mojombo
378
71k
Testing 201, or: Great Expectations
jmmastey
46
8.1k
Build your cross-platform service in a week with App Engine
jlugia
234
18k
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
1
68
VelocityConf: Rendering Performance Case Studies
addyosmani
333
24k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
31
10k
Transcript
Introduction to "Chef" framework Silesian Ruby Users Group Wojciech Wn¦trzak
December 3, 2010
What Is Chef? Open Source (Apache License v. 2.0) Framework
Ruby Infrastructure conguration management tool
Chef Is Young Released on January 15th, 2009
Why To Use Chef? Only one administration guy in company?
Forces order in system Existing solutions for your problems Best practices
How To Use Chef? chef-client + chef-server chef-client + Opscode
Platform chef-solo
Chef Server Ruby gem (chef-server) Stores cookbooks Stores information about
nodes Accessbile by REST API
Chef Server Elements CouchDB stores node informations SOLR
data indexing RabbitMQ helps in indexing Merb API and web user interface
Chef Server Elements CouchDB stores node informations SOLR
data indexing RabbitMQ helps in indexing Merb API and web user interface That is lot of stu!
Opscode Platform Free plan (upto 5 nodes) Conguration step by
step Organizations and users managment
Chef Client Ruby gem (chef) Runs on machine that we
want to congure Communicates with chef server Authenticates using RSA keys
Server Clients
Chef Solo Part of chef gem Standalone run (without connecting
to server) Uses cookbooks from local tarballs
Simple Workow Write cookbook with recipe Upload it to chef
server Dene run list by: editing node on chef server passing JSON le to chef-client Run chef-client on desired machine
Cookbooks Cookbooks for Chef are like RubyGems for Ruby 1
1I couldn't nd author
Cookbook Skeleton
Example Attributes File set[:postgresql][:version] = "8.4" set[:postgresql][:dir] = "/etc/postgresql/{node[:postgresql][:version]}/main"
PostgreSQL Server Recipe include_recipe "postgresql::client" package "postgresql-{node[:postgresql][:version]}" do action :install
end template "{node[:postgresql][:dir]}/postgresql.conf" do source "postgresql.conf.erb" owner "postgres" group "postgres" mode "0600" end service "postgresql-{node[:postgresql][:version]}" do action :start end
Recipe Features include_recipe "postgresql::client" package "postgresql-{node[:postgresql][:version]}" service "postgresql" do service_name
"postgresql-{node[:postgresql][:version]}" supports :restart => true, :status => true action :nothing end template "{node[:postgresql][:dir]}/postgresql.conf" do source "postgresql.conf.erb" owner "postgres" group "postgres" mode "0600" notifies :restart, "service[postgresql]" end
Package Providers Apt Yum MacPorts
Package Providers Apt Yum MacPorts Many more
Supported Systems Debian Gentoo FreeBSD MacOSX Solaris
Supported Systems Debian Gentoo FreeBSD MacOSX Solaris Windows
Supported Systems Debian Gentoo FreeBSD MacOSX Solaris Windows And more
Resources2 package template le user execute script (bash, ruby, perl,
python, csh) http_request deploy 2http://wiki.opscode.com/display/chef/Resources
Resources2 package template le user execute script (bash, ruby, perl,
python, csh) http_request deploy Many more 2http://wiki.opscode.com/display/chef/Resources
Additional Tools - Ohai Released as a gem ohai
Collects system conguration/information Returns JSON
Additional Tools - Knife Part of chef gem Console tool
for chef server managment
Tips If using RVM, use rvmsudo for chef-client Take a
look at chef bootstrap3 Remember that Ruby (Chef) uses sh, not bash 3http://wiki.opscode.com/display/chef/Bootstrap+Chef+RubyGems+ Installation
Useful Links http://www.opscode.com/chef/ http://help.opscode.com/faqs/start/how-to-get-started http://cookbooks.opscode.com/ https://github.com/opscode/cookbooks
Thank You Questions?