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 Volumes and Networking
Search
ehazlett
September 30, 2015
Technology
0
51
Docker Volumes and Networking
Presentation from Docker Indianapolis:
http://www.meetup.com/Docker-Indianapolis/events/225508133/
ehazlett
September 30, 2015
Tweet
Share
Other Decks in Technology
See All in Technology
疲弊しない!AWSセキュリティ統制の考え方 #devio_osakaday1
masahirokawahara
6
5.9k
日本におけるデータエンジニアリングのこれまでとこれから
foursue
10
2.2k
AWS を使う上で知っておきたいオンプレミス知識/aws-on-premise-essentials
emiki
1
4.2k
株式会社EventHub・エンジニア採用資料
eventhub
0
1.9k
巨大なテーブルのテーブル定義を無停止で安全に誰でも変更できるようにする / Table-definitions-for-huge-tables-can-be-modified-by-anyone-safely-and-non-disruptively
freee
1
740
OpenTelemetry を使ったトレースエグザンプラーの活用 / otel-trace-exemplar
k6s4i53rx
2
630
0→1開発における技術選定において一番大切なこと
bicstone
1
320
最近たまに見かけるTiDBってなんだ? - Findy
pingcap0315
2
580
"好き"との生活/Regularly update profile with GitHub Actions
judeeeee
0
150
レガシーをぶっ壊せ。AEONで始めるDevRelの話 / Qiita Night 2024-2-22
aeonpeople
3
150
Hands-on / Kaname Frusawa / Cloud Compare Users Meetup 2024 at University of Tokyo on April 17
paraworld
2
470
Apple Vision Pro trial session
akkeylab
0
120
Featured
See All Featured
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
243
20k
Building an army of robots
kneath
300
41k
Why Our Code Smells
bkeepers
PRO
331
56k
Build your cross-platform service in a week with App Engine
jlugia
225
17k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
15
1.4k
Typedesign – Prime Four
hannesfritz
36
2.1k
Robots, Beer and Maslow
schacon
PRO
155
7.9k
A better future with KSS
kneath
231
16k
Building Adaptive Systems
keathley
30
1.8k
YesSQL, Process and Tooling at Scale
rocio
163
13k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
226
51k
Learning to Love Humans: Emotional Interface Design
aarron
266
39k
Transcript
Docker Volumes and Networking @ehazlett
Volumes
What are Docker Volumes? • Storage outside of the container
• Data persistence • Can be shared between containers • Support for plugins
Container Storage • Volumes provide storage outside of the container
• For example: • docker volume create --name foo • Inspect: • docker volume inspect foo • Creates a volume with storage path: • /mnt/docker/volumes/foo/_data
Persistence • Volumes are outside of the container • For
example (using the previous example volume): • docker run -ti -v foo:/data alpine ash • Data will persist in this volume when container exits • New container can re-use this persistent volume
Sharing • Data can be shared with volumes • docker
run -ti -v foo:/data alpine ash • docker run -ti -v foo:/data busybox sh
Volume Plugins • Plugins allow custom volume storage • For
example: s3, ebs, key-whiz, vault, etc • Simple interface for writing your own • For example, Vault to share keys between containers
Networking
What’s Coming? • Overlay network • Creates multi-host network across
machines • Containers share network
Networking • Create a network • docker network create -d
overlay prod
Services • Create a service on first host • docker
service publish app1.prod • Create a service on second host • docker service publish app2.prod
Services (cont) • Run a container on first host •
cid=$(docker run -d -ti -p 80:80 nginx) • Attach container to service • docker service attach $cid app1.prod
Services (cont) • Run a container on second host •
cid=$(docker run -d -ti -p 80:80 nginx) • Attach container to service • docker service attach $cid app2.prod
Docker Networking
Thank you! • Vault Volume Driver: https://github.com/calavera/docker-volume-vault • Network: https://github.com/docker/libnetwork/blob/master/docs/overlay.md
• Docker Experimental: https://github.com/docker/docker/tree/master/experimental