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
Configuration Management Camp 2015
Search
someara
February 03, 2015
Technology
1
420
Configuration Management Camp 2015
Ghent Belgium
someara
February 03, 2015
Tweet
Share
More Decks by someara
See All by someara
Docker Docker Docker Chef
someara
0
340
Hand Crafted Artisinal Chef Resources
someara
0
450
Cookbook Reusability
someara
0
420
TDI with ChefDK 0.0.1
someara
2
480
Configuration Management 101 @ Scale12x
someara
2
740
Configuration Management 101
someara
3
630
Introduction to Chef - Scale 10x
someara
2
380
Introduction to Chef - NYLUG Jan 2012
someara
2
250
Introduction to Chef - LISA11
someara
10
6k
Other Decks in Technology
See All in Technology
サーバー間 GraphQL と webmock-graphql の話 / server-to-server graphql and webmock-graphql
qsona
2
190
本当のAWS基礎
toru_kubota
0
520
一生覚えておきたい「システム開発=コミュニケーション」〜初めての実務案件振り返りLT〜
maimyyym
0
140
KubeCon EU 2024 Recap “Kubernetes Policy Time Machine: Where to Next?”
ryysud
0
220
FrontDoorとWebAppsを組み合わせた際のリダイレクト処理の注意点
kenichirokimura
1
510
Terraformあれやこれ/terraform-this-and-that
emiki
8
1.4k
Cloud Native Java with Spring Boot (CNCF Aarhus, April 2024)
thomasvitale
1
170
ServiceNow Knowledge Learning Rise up
manarobot
0
210
Google Cloud の AI を支える裏側のインフラを垣間見る!
maroon1st
0
340
require(ESM)とECMAScript仕様
uhyo
3
530
Gitlab本から学んだこと - そーだいなるプレイバック / gitlab-book
soudai
4
360
Google Cloud Next '24でブログを10本書いた方法と勉強会を沸かせた方法
yasumuusan
0
290
Featured
See All Featured
What the flash - Photography Introduction
edds
64
11k
VelocityConf: Rendering Performance Case Studies
addyosmani
320
23k
Thoughts on Productivity
jonyablonski
58
3.8k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
659
120k
Automating Front-end Workflow
addyosmani
1356
200k
Building Your Own Lightsaber
phodgson
99
5.7k
Fashionably flexible responsive web design (full day workshop)
malarkey
398
65k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
25
2.3k
GraphQLの誤解/rethinking-graphql
sonatard
50
9.2k
Optimizing for Happiness
mojombo
370
69k
ParisWeb 2013: Learning to Love: Crash Course in Emotional UX Design
dotmariusz
104
6.6k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
274
13k
Transcript
Chef Reusability! Config Management Camp! Ghent, Belgium! February 2015
Sean OMeara!
[email protected]
! @someara
whoami
Part 1
Things that are true
New Chef users expect community cookbooks to just work
Especially the Chef maintained cookbooks
This is not the current state of things
This leads to sadness
We must repair it
People copy patterns
The status quo cannot be allowed to continue
Common pain points https://www.flickr.com/photos/kwl/4595324641
Platform and version support
Weak scoping
No standard interface
Compilation phase work
Needing chef-rewind
Attributes and precedence
Pattern proliferation
The path out of the darkness https://www.flickr.com/photos/71267357@N06/15864687537
Change how cookbooks are written
systems beliefs! behaviors
Standardize interfaces
Eliminate the pain points
Focus on resources
Make it super easy! to write resources
Ship resources for ALL THE THINGS
Copy better patterns
Make it fucking delightful
None
Part 2
Simple design patterns https://www.flickr.com/photos/pollock/4172865252
None
None
You just separated data from code
You also just built an interface
Complex design patterns https://www.flickr.com/photos/alanosaur/6417040565
None
None
This is where things get weird
amazon debian-6 debian-7 ubuntu-10.04 ubuntu-12.04 ubuntu-14.04 centos-5 centos-6 centos-7 freebsd-9
freebsd-10
Debconf! Docker! LaunchD! Runit! SMF! Simple! SystemD! Sysvinit! Upstart! Windows
Services
There is a large amount of variation between software versions
There is an insane amount variation across platforms
These differences need to be handled somewhere
Early techniques did everything in the recipe
data resource pattern
Later techniques focused on isolation
Resource pattern isolation
None
private recipes by convention
Resource data isolation
None
None
We now have decision logic in our interface
Default values often need to be computed
Doing this in the interface leads to sorrow
None
We need a better way
Consumption Patterns https://www.flickr.com/photos/ektogamat/2578779839
None
None
None
None
Why resources are best https://www.flickr.com/photos/cross_stitch_ninja/4932950637
node attributes roles environments databags are nice to haves
They drive data about resources
Resources are fundamental
Resources are strongly scoped
Resources have a standardized interface
Resources have types, names, and parameters
Type
Name
Parameters
Resources have identities
None
Resource can see each other
Promise to talk
Promise to listen
Resource behave the same across platforms
None
None
None
Resource can have multiple providers
None
Writing simple resources
yum
</switches github>
Writing complex resources
mysql httpd
</switches github>
fin