intro 2 docker

21
Introduction to Docker Build, run and scale

Upload: hanoijug

Post on 22-Jan-2018

397 views

Category:

Technology


0 download

TRANSCRIPT

Page 1: Intro 2 docker

Introduction to

DockerBuild, run and scale

Page 2: Intro 2 docker

About Me

● Vincent Sellier○ @vsellier

● Operations manager at eXo

Page 3: Intro 2 docker

Agenda

Enjoy...

1. Docker fundamentals2. Tools and Ecosystem

And demos

Page 4: Intro 2 docker

Dockerfundamentals

Page 5: Intro 2 docker

What is a container ?

Page 6: Intro 2 docker

What is Docker ?

● The docker engine is a wrapper for :○ Namespaces○ cgroups○ Union file systems

● Hide the underlying complexity

Page 7: Intro 2 docker

Union filesystem

Layer 1Layer 2

Layer 3Layer 4

Layer 5Active layer

Read

Write

Page 8: Intro 2 docker

3 important concepts

1. Immutability2. Rapidity3. Portability

Page 9: Intro 2 docker

Docker trends

Page 10: Intro 2 docker

Docker

Tools

Page 11: Intro 2 docker

Installation

● Supported by all recent linux distros○ Package managers○ One line installer○ CoreOs : Fully docker oriented distros

● Supported on Mac and Windows

Page 12: Intro 2 docker

docker-machine● Provision and configure docker hosts● almost 15 supported drivers

○ VirtualBox○ AWS○ GoogleCloud○ Microsoft Azure○ VMware vSphere○ OpenStack○ ...

Page 13: Intro 2 docker

Docker Hub

● Online service maintained by Docker inc● Image repository with versioning● Content trust● Public / Private spaces● A private registry is available

Page 14: Intro 2 docker

The Dockerfile

● Simple DSL to extend images○ Configure the base image○ Update the content○ Configure the startup behavior

● Each instruction results in one images layer

Page 15: Intro 2 docker

Data volumes

● Special directories excluded from the Union File System● Persistents● Sharable between containers

Page 16: Intro 2 docker

Networking and container links

● bind ports on docker hosts● link two containers or more

○ Configure the network○ Create an alias in the hosts file○ Inherit ENV instructions from the source container○ Support restart

Page 17: Intro 2 docker

docker-compose

● Define multi-container applications in one file● Manage container dependencies● Can build images● Scale applications

Page 18: Intro 2 docker

docker-swarm

● Docker clustering● Transparent for docker tools● Host selector● Support the new 1.9 docker network feature

Page 19: Intro 2 docker

docker-swarm

dockerdocker-compose

swarm-master

discovery service

docker hostdocker host

docker hostdocker host

Page 20: Intro 2 docker

Questions ?

Page 21: Intro 2 docker

Thanks