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
Docker Docker Docker Chef
Search
someara
February 02, 2016
Technology
0
370
Docker Docker Docker Chef
Configuration Management Camp
Ghent Belgium
February 2016
someara
February 02, 2016
Tweet
Share
More Decks by someara
See All by someara
Hand Crafted Artisinal Chef Resources
someara
0
480
Configuration Management Camp 2015
someara
1
450
Cookbook Reusability
someara
0
480
TDI with ChefDK 0.0.1
someara
2
540
Configuration Management 101 @ Scale12x
someara
2
760
Configuration Management 101
someara
3
660
Introduction to Chef - Scale 10x
someara
2
400
Introduction to Chef - NYLUG Jan 2012
someara
2
260
Introduction to Chef - LISA11
someara
10
6.1k
Other Decks in Technology
See All in Technology
ギークの理想が7つ集まるエムスリーで夢を叶えよう - エムスリー株式会社
m3_engineering
1
260
20240725 LLMによるDXのビジョンと、今何からやるべきか @Azure OpenAI Service Dev Day
nrryuya
3
1.2k
Flutter研修【MIXI 24新卒技術研修】
mixi_engineers
PRO
0
160
ACRiルーム最新情報とAMD GPUサーバーのご紹介
anjn
0
150
Docker互換のセキュアなコンテナ実行環境「Podman」超入門
devops_vtj
6
3.2k
サーバーレスAPI(API Gateway+Lambda)とNext.jsで 個人ブログを作ろう!
shuntaka
PRO
0
560
AutomatedLabを使って内部ペンテストを勉強しよう! -やられ社内ネットワークの自動構築-
n_etupirka
1
610
AI研修【MIXI 24新卒技術研修】
mixi_engineers
PRO
0
130
Azure Pipelinesを使用したCICDベースラインアーキテクチャ実践
yuriemori
0
190
20240717_イケコパ代表Copilot_in_Teams会社でこう使ってます
ponponmikankan
2
430
開発生産性をむしろ向上させる セキュリティパートナーの作り方 / Dev Productivity Con 2024
flatt_security
0
360
Amazon FSx for NetApp ONTAPのパフォーマンスチューニング要素をまとめてみた #cm_odyssey #devio2024
non97
0
220
Featured
See All Featured
YesSQL, Process and Tooling at Scale
rocio
166
14k
Practical Orchestrator
shlominoach
185
10k
A designer walks into a library…
pauljervisheath
201
24k
Building Effective Engineering Teams - LeadDev
addyosmani
47
2.2k
Code Review Best Practice
trishagee
58
16k
Building Adaptive Systems
keathley
34
2k
From Idea to $5000 a Month in 5 Months
shpigford
377
46k
VelocityConf: Rendering Performance Case Studies
addyosmani
321
23k
Atom: Resistance is Futile
akmur
261
25k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
23
1.9k
Design by the Numbers
sachag
277
18k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
277
13k
Transcript
Docker Docker Docker Chef
Config Management Camp Ghent, Belgium February 2016
Sean OMeara
[email protected]
@someara
whoami
Part 1
Remember the time
Remember that time we didn’t need configuration management because we
had packaging?
Remember that time the cloud came out and we didn’t
need sysadmins?
Remember that time when we didn’t need schemas because we
had MongoDB?
Repeat after me
CONFIGURATION MANAGEMENT AND IMMUTABLE INFRASTRUCTURE ARE NOT MUTUALLY EXCLUSIVE
Say it again
CONFIGURATION MANAGEMENT AND IMMUTABLE INFRASTRUCTURE ARE NOT MUTUALLY EXCLUSIVE
We good?
The Docker cookbook
Configuration Management is not restricted to files, directories, packages and
services
Configuration Management tests and repairs any programmable noun
Images are nouns
Containers are nouns
hello world
https://flic.kr/p/br26Cb Setup v0.0.1
Install ChefDK
git clone https:// github.com/someara/chef- docker-tutorial
kitchen test
git checkout v0.0.1 git checkout v0.1.0 git checkout v0.1.1 git
checkout v0.2.0 git checkout v0.2.1 git checkout v0.3.0 git checkout v0.3.1
https://flic.kr/p/s684tk Feature v0.1.0
metadata.rb
.kitchen.yml
recipes/hello.rb
kitchen converge hello kitchen login hello docker images docker ps
-a docker logs hello-world
git add . git commit -a -m “v0.1.0 - hello”
git tag v0.1.0
https://flic.kr/p/53stX2 Patch v0.1.1
Bug report: “hello is not idempotent”
kitchen converge hello kitchen converge hello
kitchen login hello docker ps -a docker logs hello-world
hello-world exits after every run
This is expected!
http://gliderlabs.com/
recipes/hello.rb
rubocop \ && rspec \ && kitchen test hello
metadata.rb
git add . git commit -a -m “v0.1.1 - hello”
git tag v0.1.1
an echo server https://flic.kr/p/6WtX6X
https://flic.kr/p/s684tk Feature v0.2.0
Recipe work Kitchen work Behavior testing Unit Final Acceptance Commit
.kitchen.yml
recipes/echo.rb
Docker Containers have 40+ (and growing) runtime API options
None
kitchen converge echo kitchen converge echo kitchen login echo docker
images docker ps -a docker logs an_echo_server docker inspect an_echo_server echo "hi" | nc localhost 7
test/integration/echo/inspec/run_spec.rb
rubocop \ && rspec \ && kitchen test echo
metadata.rb
git add . git commit -a -m “v0.2.0 - echo”
git tag v0.2.0
https://flic.kr/p/dRGr3t Patch v0.2.1
Security team recommends a change… Service should listen on explicitly
defined interfaces
kitchen converge echo kitchen login echo netstat -anp
Listening on :::7 Let’s fix that.
recipes/echo.rb
test/integration/echo/inspec/run_spec.rb
rubocop \ && rspec \ && kitchen test echo
metadata.rb
git add . git commit -a -m “v0.2.1 - echo
patch” git tag v0.2.1
https://flic.kr/p/ayDujN notifications and subscriptions
https://flic.kr/p/cNdyo Feature v0.3.0
recipes/web.rb
recipes/web.rb
kitchen converge web kitchen converge web kitchen login web docker
images docker ps -a curl localhost docker logs bob
test/integration/web/inspec/run_spec.rb
rubocop \ && rspec \ && kitchen test web
metadata.rb
git add . git commit -a -m “v0.3.0 - web”
git tag v0.3.0
https://flic.kr/p/o9c2G3 Patch v0.3.1
Marketing team recommends a change… Bob wasn’t there.
kitchen converge web kitchen login web curl localhost
Bob was here. Let’s fix that.
recipes/web.rb
test/integration/echo/inspec/run_spec.rb
rubocop \ && rspec \ && kitchen test web
metadata.rb
git add . git commit -a -m “v0.3.1 - echo
patch” git tag v0.3.1
Part 2
kitchen-dokken http://on.mtv.com/1ls5SRc
Experimental status Soon to be renamed something less clever
Removes bootstrap overhead Uses Docker volumes Chef not baked into
images Works on Travis
https://github.com/someara/ kitchen-dokken/
Install ChefDK chef gem install kitchen-dokken
git clone https://github.com/ someara/hello_dokken
kitchen list docker ps -a
None
kitchen create docker ps -a
Chef container Data container Runner container
docker run \ —volumes-from chef \ —volumes-from data \ imagename
\ chef-client
docker diff suitename
https://travis-ci.org/ someara/etcd-cookbook
fin
None