Ce diaporama a bien été signalé.
Nous utilisons votre profil LinkedIn et vos données d’activité pour vous proposer des publicités personnalisées et pertinentes. Vous pouvez changer vos préférences de publicités à tout moment.
Why?
Contents
• The challenge
Pre-[package] dev stack
• WAMP, XAMP
• Java/Tomcat
• Ruby/Rail
It works on MY machine
VM
• closely production env
• annoying configure
Provision a server without logging in
• Ansible, puppet, salt, Chef
• Pre-configure
• Pre-setup
• Environment-path
•  by ...
Simple, repeatable VMs
Market View: Evolution of IT
1995 2015
Running on any
available set of
physical resources
(public/private/
virtualized)
As...
Challenges
2015
How to ensure services
interact consistently,
avoid dependency hell
How to migrate & scale
quickly, ensure...
Static website
Web frontend
User DB
Queue Analytics DB
Background workers
API endpoint
nginx 1.5 + modsecurity + openssl +...
Results in N X N compatibility nightmare
Static website
Web frontend
Background workers
User DB
Analytics DB
Queue
Develop...
A useful analogy…
MultiplicityofGoods
Multipilicityof
methodsfor
transporting/storing
DoIworryabout
howgoodsinteract
(e.g.coffeebeans
nextto...
? ? ? ? ? ? ?
? ? ? ? ? ? ?
? ? ? ? ? ? ?
? ? ? ? ? ? ?
? ? ? ? ? ? ?
? ? ? ? ? ? ?
Also an NxN Matrix
Contents
• The challenge
• The solution
MultiplicityofGoods
Multiplicityof
methodsfor
transporting/storing
DoIworryabout
howgoodsinteract
(e.g.coffeebeans
nexttos...
This eliminated the NXN problem…
and spawned an Intermodal Shipping Container Ecosystem
• 90% of all cargo now shipped in a standard container
• Order of m...
Static website Web frontendUser DB Queue Analytics DB
Development
VM
QA server Public Cloud Contributor’s
laptop
Docker is...
Static website Web frontendUser DB Queue Analytics DB
Development
VM
QA server Public Cloud Contributor’s
laptop
Or…put mo...
Static website
Web frontend
Background workers
User DB
Analytics DB
Queue
Development
VM
QA Server
Single Prod
Server
Onsi...
Why containers matter
Physical Containers Docker
Content Agnostic The same container can hold almost any
type of cargo
Can...
Container
• A container is a stripped-to-basics (mimic OS kernel) version of
a Linux operating system.
Image
• An image is software you load into a container.
• hello-world: is simple app, can do a simple task as echo
• Wordp...
App
A
Containers vs. VMs
Hypervisor (Type 2)
Host OS
Server
Guest
OS
Bins/
Libs
App
A’
Guest
OS
Bins/
Libs
App
B
Guest
OS
...
Why are Docker containers lightweight?
Bins/
Libs
App
A
Original App
(No OS to take
up space, resources,
or require restar...
Changes and Updates
Docker Engine
Docker
Container
Image
Registry
Docker Engine
Push
Update
Bins/
Libs
App
A
AppΔ
Bins/
Ba...
Why we need container in Software
Prochain SlideShare
Chargement dans…5
×

Why we need container in Software

493 vues

Publié le

Fast research to talk about Docker and why we need something like a real-life container in software.
Container will help to separated pieces of "things", standardize transportation, package, unpack, ...

Publié dans : Logiciels
  • Soyez le premier à commenter

  • Soyez le premier à aimer ceci

Why we need container in Software

  1. 1. Why?
  2. 2. Contents • The challenge
  3. 3. Pre-[package] dev stack • WAMP, XAMP • Java/Tomcat • Ruby/Rail
  4. 4. It works on MY machine
  5. 5. VM • closely production env • annoying configure
  6. 6. Provision a server without logging in • Ansible, puppet, salt, Chef • Pre-configure • Pre-setup • Environment-path •  by a shell script
  7. 7. Simple, repeatable VMs
  8. 8. Market View: Evolution of IT 1995 2015 Running on any available set of physical resources (public/private/ virtualized) Assembled by developers using best available services Thin app on mobile, tabletThick, client-server app on thick client Well-defined stack: - O/S - Runtime - Middleware Monolithic Physical Infrastructure
  9. 9. Challenges 2015 How to ensure services interact consistently, avoid dependency hell How to migrate & scale quickly, ensure compatibility How to avoid n X n different configs Running on any available set of physical resources (public/private/ virtualized) Assembled by developers using best available services Thin app on mobile, tablet
  10. 10. Static website Web frontend User DB Queue Analytics DB Background workers API endpoint nginx 1.5 + modsecurity + openssl + bootstrap 2 postgresql + pgv8 + v8 hadoop + hive + thrift + OpenJDK Ruby + Rails + sass + Unicorn Redis + redis-sentinel Python 3.0 + celery + pyredis + libcurl + ffmpeg + libopencv + nodejs + phantomjs Python 2.7 + Flask + pyredis + celery + psycopg + postgresql-client Development VM QA server Public Cloud Disaster recovery Contributor’s laptop Production Servers The ChallengeMultiplicityofStacks Multiplicityof hardware environments Production Cluster Customer Data Center Doservicesandapps interact appropriately? CanImigrate smoothlyand quickly?
  11. 11. Results in N X N compatibility nightmare Static website Web frontend Background workers User DB Analytics DB Queue Development VM QA Server Single Prod Server Onsite Cluster Public Cloud Contributor’s laptop Customer Servers ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?
  12. 12. A useful analogy…
  13. 13. MultiplicityofGoods Multipilicityof methodsfor transporting/storing DoIworryabout howgoodsinteract (e.g.coffeebeans nexttospices) CanItransportquickly andsmoothly (e.g.fromboattotrain totruck) Cargo Transport Pre-1960
  14. 14. ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? Also an NxN Matrix
  15. 15. Contents • The challenge • The solution
  16. 16. MultiplicityofGoods Multiplicityof methodsfor transporting/storing DoIworryabout howgoodsinteract (e.g.coffeebeans nexttospices) CanItransport quicklyandsmoothly (e.g.fromboatto traintotruck) Solution: Intermodal Shipping Container …in between, can be loaded and unloaded, stacked, transported efficiently over long distances, and transferred from one mode of transport to another A standard container that is loaded with virtually any goods, and stays sealed until it reaches final delivery.
  17. 17. This eliminated the NXN problem…
  18. 18. and spawned an Intermodal Shipping Container Ecosystem • 90% of all cargo now shipped in a standard container • Order of magnitude reduction in cost and time to load and unload ships • Massive reduction in losses due to theft or damage • Huge reduction in freight cost as percent of final goods (from >25% to <3%)  massive globalizations • 5000 ships deliver 200M containers per year
  19. 19. Static website Web frontendUser DB Queue Analytics DB Development VM QA server Public Cloud Contributor’s laptop Docker is a shipping container system for code MultiplicityofStacks Multiplicityof hardware environments Production Cluster Customer Data Center Doservicesandapps interact appropriately? CanImigrate smoothlyandquickly …that can be manipulated using standard operations and run consistently on virtually any hardware platform An engine that enables any payload to be encapsulated as a lightweight, portable, self-sufficient container…
  20. 20. Static website Web frontendUser DB Queue Analytics DB Development VM QA server Public Cloud Contributor’s laptop Or…put more simplyMultiplicityofStacks Multiplicityof hardware environments Production Cluster Customer Data Center Doservicesandapps interact appropriately? CanImigrate smoothlyandquickly Operator: Configure Once, Run Anything Developer: Build Once, Run Anywhere (Finally)
  21. 21. Static website Web frontend Background workers User DB Analytics DB Queue Development VM QA Server Single Prod Server Onsite Cluster Public Cloud Contributor’s laptop Customer Servers Docker solves the NXN problem
  22. 22. Why containers matter Physical Containers Docker Content Agnostic The same container can hold almost any type of cargo Can encapsulate any payload and its dependencies Hardware Agnostic Standard shape and interface allow same container to move from ship to train to semi-truck to warehouse to crane without being modified or opened Using operating system primitives (e.g. LXC) can run consistently on virtually any hardware—VMs, bare metal, openstack, public IAAS, etc.—without modification Content Isolation and Interaction No worry about anvils crushing bananas. Containers can be stacked and shipped together Resource, network, and content isolation. Avoids dependency hell Automation Standard interfaces make it easy to automate loading, unloading, moving, etc. Standard operations to run, start, stop, commit, search, etc. Perfect for devops: CI, CD, autoscaling, hybrid clouds Highly efficient No opening or modification, quick to move between waypoints Lightweight, virtually no perf or start-up penalty, quick to move and manipulate Separation of duties Shipper worries about inside of box, carrier worries about outside of box Developer worries about code. Ops worries about infrastructure.
  23. 23. Container • A container is a stripped-to-basics (mimic OS kernel) version of a Linux operating system.
  24. 24. Image • An image is software you load into a container. • hello-world: is simple app, can do a simple task as echo • Wordpress: is complex app, run database, wait for data, ... • or setup Ubuntu bash shell
  25. 25. App A Containers vs. VMs Hypervisor (Type 2) Host OS Server Guest OS Bins/ Libs App A’ Guest OS Bins/ Libs App B Guest OS Bins/ Libs AppA’ Docker Host OS Server Bins/Libs AppA Bins/Libs AppB AppB’ AppB’ AppB’ VM Container Containers are isolated, but share OS and, where appropriate, bins/libraries Guest OS Guest OS
  26. 26. Why are Docker containers lightweight? Bins/ Libs App A Original App (No OS to take up space, resources, or require restart) AppΔ Bins/ App A Bins/ Libs App A’ Guest OS Bins/ Libs Modified App Union file system allows us to only save the diffs Between container A and container A’ VMs Every app, every copy of an app, and every slight modification of the app requires a new virtual server App A Guest OS Bins/ Libs Copy of App No OS. Can Share bins/libs App A Guest OS Guest OS VMs Containers
  27. 27. Changes and Updates Docker Engine Docker Container Image Registry Docker Engine Push Update Bins/ Libs App A AppΔ Bins/ Base Container Image Host is now running A’’ Container Mod A’’ AppΔ Bins/ Bins/ Libs App A Bins/ Bins/ Libs App A’’ Host running A wants to upgrade to A’’. Requests update. Gets only diffs Container Mod A’

×