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
Wojciech Wnętrzak
December 05, 2011
Programming
6
340
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
28
Other Decks in Programming
See All in Programming
VS Code Update for GitHub Copilot
74th
2
630
Hack Claude Code with Claude Code
choplin
0
190
High-Level Programming Languages in AI Era -Human Thought and Mind-
hayat01sh1da
PRO
0
750
5つのアンチパターンから学ぶLT設計
narihara
1
160
新メンバーも今日から大活躍!SREが支えるスケールし続ける組織のオンボーディング
honmarkhunt
4
6.1k
What Spring Developers Should Know About Jakarta EE
ivargrimstad
0
430
AIともっと楽するE2Eテスト
myohei
0
170
PHP 8.4の新機能「プロパティフック」から学ぶオブジェクト指向設計とリスコフの置換原則
kentaroutakeda
2
750
ペアプロ × 生成AI 現場での実践と課題について / generative-ai-in-pair-programming
codmoninc
1
15k
dbt民主化とLLMによる開発ブースト ~ AI Readyな分析サイクルを目指して ~
yoshyum
3
810
XP, Testing and ninja testing
m_seki
3
240
Claude Code + Container Use と Cursor で作る ローカル並列開発環境のススメ / ccc local dev
kaelaela
0
380
Featured
See All Featured
Code Review Best Practice
trishagee
69
18k
Balancing Empowerment & Direction
lara
1
410
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
15
1.5k
Large-scale JavaScript Application Architecture
addyosmani
512
110k
Java REST API Framework Comparison - PWX 2021
mraible
31
8.7k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
10
950
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
45
7.5k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
A Tale of Four Properties
chriscoyier
160
23k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
7
730
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
30
2.1k
Facilitating Awesome Meetings
lara
54
6.4k
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?