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
Use Datacenter Tools to Make Your Dev Life Easier
Search
Jochen Lillich
August 23, 2012
Programming
0
96
Use Datacenter Tools to Make Your Dev Life Easier
Talk at DrupalCon Munich 2012 about using Chef and Vagrant in a development environment
Jochen Lillich
August 23, 2012
Tweet
Share
More Decks by Jochen Lillich
See All by Jochen Lillich
Under Pressure
geewiz
0
47
Monorepo vs Multirepo
geewiz
0
62
Dealing with IRQ conflicts in 2018
geewiz
0
49
Planning for the Unpredictable
geewiz
0
170
Captaining a Container Ship
geewiz
0
69
Content - Culture - Community
geewiz
0
360
Drupal on Docker
geewiz
0
210
Getting the most out of Varnish (DrupalCamp Galway 2014)
geewiz
0
220
DevOps with Drupal
geewiz
0
310
Other Decks in Programming
See All in Programming
GitHub Copilot for Azureを使い倒したい
ymd65536
1
200
ウォンテッドリーの「ココロオドル」モバイル開発 / Wantedly's "kokoro odoru" mobile development
kubode
1
190
Dissecting and Reconstructing Ruby Syntactic Structures
ydah
2
1.2k
「影響が少ない」を自分の目でみてみる
o0h
PRO
2
1.2k
Empowering Developers with HTML-Aware ERB Tooling @ RubyKaigi 2025, Matsuyama, Ehime
marcoroth
2
790
Fiber Scheduler vs. General-Purpose Parallel Client
hayaokimura
1
110
Qiita Bash
mercury_dev0517
2
210
Golangci-lint v2爆誕: 君たちはどうすべきか
logica0419
1
170
SwiftDataのカスタムデータストアを試してみた
1mash0
0
110
On-the-fly Suggestions of Rewriting Method Deprecations
ohbarye
1
3.5k
Jakarta EE Meets AI
ivargrimstad
0
300
Orleans + Sekiban + SignalR でリアルタイムWeb作ってみた
tomohisa
0
130
Featured
See All Featured
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
178
53k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
667
120k
A designer walks into a library…
pauljervisheath
205
24k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
248
1.3M
Visualization
eitanlees
146
16k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
8
670
Stop Working from a Prison Cell
hatefulcrawdad
268
20k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
29
2.5k
GitHub's CSS Performance
jonrohan
1030
460k
The World Runs on Bad Software
bkeepers
PRO
68
11k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
Site-Speed That Sticks
csswizardry
5
500
Transcript
freistil.it Use datacenter tools to make your dev life easier
Jochen Lillich
About me
Jochen Lillich @geewiz * 1970 Linux Sysadmin & Trainer IT
Manager at WEB.DE, 1&1 Founder & CTO at freistil IT
freistil IT http://freistil.it @freistil “Ops for Devs” DrupalCONCEPT: Drupal IaaS
Challenge... Local development environments Manual configuration effort Mismatched software versions
Long onboarding times
...accepted! Minimize setup time Make Development = Production Reproduce setup
consistently on demand
Vagrant
“Vagrant uses Oracle’s VirtualBox to build configurable, lightweight, and portable
virtual machines dynamically.” http://vagrantup.com
$ gem install vagrant $ vagrant box add precise64 http://
files.vagrantup.com/precise64.box $ cd ~/myvm $ vagrant init precise64 $ vagrant up $ vagrant ssh Instant VM
Pre-installed OS Available from http://files.vagrantup.com Box
Box – Management $ vagrant box -h $ vagrant package
-h
Box – DIY VeeWee by Patrick Dubois https://github.com/jedi4ever/veewee
Vagrantfile Ruby DSL for VM configuration Can be used for
many VMs
Vagrant::Config.run do |config| config.vm.box = "precise64" config.vm.boot_mode = :gui config.vm.forward_port
80, 8080 end Vagrantfile
“Well, I’ve been doing that for ages with snapshots/ images/other...”
None
“No matter how complex the realities of your business, Chef
makes it easy to deploy servers and scale applications throughout your entire infrastructure.” http://www.opscode.com/chef/
Ruby DSL for system administration tasks Makes only necessary changes
(Idempotence) CM with Chef
Infrastructure as Code Cookbooks Recipes Resources Providers Nodes Attributes Roles
Resources Package Service File, Directory Template Command, Script Cron Git
...
Example package ”apache2” do action :install end service ”apache2” do
action [:enable, :start] end
Example (cont.) template ”/etc/apache2/apache2.conf” do source ”apache2.conf.erb” owner ”root” group
”root” mode 0644 notifies ”reload”, ”service[apache2]” end
Community sites http://wiki.opscode.com http://community.opscode.com http://github.com/opscode-cookbooks
+
Installation $ gem install librarian $ cd ~/myvm $ librarian-chef
init $ $EDITOR Cheffile $ librarian-chef install
Cheffile site ”http://community.opscode.com/api/v1” cookbook ’apache2’ cookbook ’php’ cookbook ’mysql’
roles/drupal.rb name "drupal" description "Drupal dev VM" run_list( "recipe[apache2]", "recipe[apache2::mod_expires]",
"recipe[apache2::mod_rewrite]", "recipe[apache2::mod_php5]", "recipe[php]", "recipe[php::module_mysql]", "recipe[mysql::client]", "recipe[mysql::server]" )
Vagrantfile config.vm.provision :chef_solo do |chef| chef.cookbooks_path = ”cookbooks” chef.roles_path =
”roles” chef.add_role ”drupal-dev” end
Kitchen magic $ vagrant provision
Now do some awesome stuff!
And finally... $ vagrant destroy
Tips Keep all building blocks local: Cache packages Store your
own base boxes Use a central cookbook repository
Conclusion Combining Vagrant and Chef gives us: Dedicated, consistent, disposable
dev setups Efficient onboarding of new devs
Thank you! Please rate my session: http://bit.ly/dc12chef