SlideShare uma empresa Scribd logo
1 de 54
Mustafa AKIN
Ankara Java Users Group
16 April 2015
What is Docker?
And what it means to you?
What is Docker?
■ An open platform
■ Portable, lightweight runtime and packaging tool
■ Automating deployment of applications inside software
containers
■ Operating-system-level virtualization
■ Isolated containers
Virtual Machines,
Hypervisors
■ KVM, kernel based virtual
machine
■ Virtualize an entire system
■ Virtual CPU
■ Virtual Hard Disk
■ Virtual Network
Containers
■ Containers share same Linux
Kernel
■ Isolation possible by
namespaces, cgroups provided
by Linux Kernel
■ Microsoft has started providing
Native Windows Containers
Containers vs Virtual
Machines
Performance of Containers
An Updated Performance Comparison of Virtual Machines and Linux Containers,
IBM Research
How does Docker Work?
■ Operating system provides you a set of system calls
■ You do not actually read file, read from socket, write output
to screen
■ Operating system handles most crucial functionality for you
■ Docker utilizes namespaces for abstracting access to system
resources
■ Docker also utilizes cgroups, that provides namespace
isolation
■ Cgroups also provide resource accounting and limitation
Namespaces
■ Mount: Isolate the set of file system mount points for
processes
■ UTS: Isolates domain name and host name
■ IPC: Inter process communication, such as shared memory,
named semaphores, message queues
■ PID: Process ID number space. So init process of each
namespace can be different
■ Network: Different network devices, routing tables
■ User: Different user ids for inside and outside of namespace
Regular htop
htop inside a container
Docker images
■ Docker mounts images as the root file system of a container
■ Images in Docker are layered: like git, you have to commit
changes to create a new image, or update the current
version
■ Image layers can be shared among containers
■ Sharing layers increases performance since the common
files will be in cache, and also reduces the disk usage
Example usage of images
Layers of images
ubuntu
jdk8
myjavaapp jetty
gcc
helloworld
Docker hub
Dockerfile
Control Groups (cgroups)
■ blkio: set limits and monitor usage of block devices such as
disks
■ cpu: scheduling, weights of tasks
■ cpuacct: usage reports of cpus
■ cpuset: assign cpus and memory nodes to tasks
■ devices: allow access to devices (webcam, gpu etc.)
■ memory: limit on memory, and usage reports
■ net_prio: priority on network interfaces
Example of cpuacct
Aggregating Docker metrics
■ My own project to gather cgroup metrics for containers:
https://github.com/mustafaakin/docker-resource-reporter
Boot2Docker
Containerizing GUI Apps
$ docker run -it 
-v /tmp/.X11-unix:/tmp/.X11-unix  # mount the X11 socket
-e DISPLAY=unix$DISPLAY  # pass the display
-v /dev/snd:/dev/snd --privileged  # sound
--name tor-browser jess/tor-browser
Containerizing Ubuntu Desktop
docker run -i -t -p 6080:6080 dorowu/ubuntu-desktop-lxde-vnc
Running a database
Mounting Data
Poor man’s Continuous
integration
Rich man’s continuous
integration
■ CircleCI
■ Bamboo
■ Jenkins
■ TravisCI
■ Shippable
PrimeFaces showcase
Running Benchmarks
Selenium Grid
Selenium Grid
PAGS: Programming
Assignment Grading System
■ http://pags.cs.bilkent.edu.tr
or http://code.gy
PAGS, Programming
Assignment Grading System
PAGS, Programming
Assignment Grading System
My Research
Twelve Factor App
I. Codebase
One codebase tracked in revision
control, many deploys
II. Dependencies
Explicitly declare and isolate
dependencies
III. Config
Store config in the environment
IV. Backing Services
Treat backing services as
attached resources
V. Build, release, run
Strictly separate build and run
stages
VI. Processes
Execute the app as one or more
stateless processes
VII. Port binding
Export services via port binding
VIII. Concurrency
Scale out via the process model
IX. Disposability
Maximize robustness with fast
startup and graceful shutdown
X. Dev/prod parity
Keep development, staging, and
production as similar as possible
XI. Logs
Treat logs as event streams
XII. Admin processes
Run admin/management tasks
as one-off processes
Heroku
Deis – Your own Heroku
Deis – Your own Heroku
Deis – Your own Heroku
IBM Bluemix
RancherOS: Dockerize
everything
Rancher UI
Docker Web UIs
Kitematic: GUI for Docker
Kubernetes by Google
Docker Compose (Fig)
Docker Swarm
Use filtering:
‱ Constraints:
‱ Labeling, SSD Server, Big
Server..
‱ Operating System
‱ Kernel Version
‱ Affinity
‱ Schedule 2 containers
together
‱ Port
‱ Availability
‱ Dependency
‱ Containers might be using
volumes, or share network
stack
Docker Machine
Docker-ready clouds
■ Amazon EC2 Container Service
■ Google Container Engine
■ Digital Ocean
Docker investments
■ Series B: 21 Jan 2014 $15M
■ Series C: 16 Sep 2014 $40M
■ Series D: 14 Apr 2015: $95M
■ Docker initial release: 13 March 2013
Windows side.. Docker
Client!
Windows side, Nano Server!
Remote API
■ HTTP over Unix Socket, TCP Socket, Optionally TLS
■ JSON API
– Create container
– Start container
– Wait container
– List containers
– Search image
– Pull/Push images
– Build image from Dockerfile
■ Hijacked HTTP API or alternatively WebSocket API for
attaching to container, to see its output in real-time
Mustafa AKIN
Twitter: @mustafaakin
Mail: mustafa91@gmail.com
Web: www.mustafaak.in
■ Feel free to contact for Docker related questions, or anything
else!

Mais conteĂșdo relacionado

Mais procurados

What Is A Docker Container? | Docker Container Tutorial For Beginners| Docker...
What Is A Docker Container? | Docker Container Tutorial For Beginners| Docker...What Is A Docker Container? | Docker Container Tutorial For Beginners| Docker...
What Is A Docker Container? | Docker Container Tutorial For Beginners| Docker...
Simplilearn
 
Docker 101: Introduction to Docker
Docker 101: Introduction to DockerDocker 101: Introduction to Docker
Docker 101: Introduction to Docker
Docker, Inc.
 

Mais procurados (20)

Docker in real life
Docker in real lifeDocker in real life
Docker in real life
 
Virtual Container - Docker
Virtual Container - Docker Virtual Container - Docker
Virtual Container - Docker
 
Docker 101 - Nov 2016
Docker 101 - Nov 2016Docker 101 - Nov 2016
Docker 101 - Nov 2016
 
Docker 101 - High level introduction to docker
Docker 101 - High level introduction to dockerDocker 101 - High level introduction to docker
Docker 101 - High level introduction to docker
 
Kubernetes Introduction
Kubernetes IntroductionKubernetes Introduction
Kubernetes Introduction
 
Containers, Docker, and Microservices: the Terrific Trio
Containers, Docker, and Microservices: the Terrific TrioContainers, Docker, and Microservices: the Terrific Trio
Containers, Docker, and Microservices: the Terrific Trio
 
Platform Orchestration with Kubernetes and Docker
Platform Orchestration with Kubernetes and DockerPlatform Orchestration with Kubernetes and Docker
Platform Orchestration with Kubernetes and Docker
 
A Shift from Monolith to Microservice using Docker
A Shift from Monolith to Microservice using DockerA Shift from Monolith to Microservice using Docker
A Shift from Monolith to Microservice using Docker
 
Docker 101
Docker 101Docker 101
Docker 101
 
What Is A Docker Container? | Docker Container Tutorial For Beginners| Docker...
What Is A Docker Container? | Docker Container Tutorial For Beginners| Docker...What Is A Docker Container? | Docker Container Tutorial For Beginners| Docker...
What Is A Docker Container? | Docker Container Tutorial For Beginners| Docker...
 
Introduction to container based virtualization with docker
Introduction to container based virtualization with dockerIntroduction to container based virtualization with docker
Introduction to container based virtualization with docker
 
Docker 101: Introduction to Docker
Docker 101: Introduction to DockerDocker 101: Introduction to Docker
Docker 101: Introduction to Docker
 
Intro to docker
Intro to dockerIntro to docker
Intro to docker
 
Infinit: Modern Storage Platform for Container Environments
Infinit: Modern Storage Platform for Container EnvironmentsInfinit: Modern Storage Platform for Container Environments
Infinit: Modern Storage Platform for Container Environments
 
Docker Basics
Docker BasicsDocker Basics
Docker Basics
 
KubeCon 2017: Kubernetes from Dev to Prod
KubeCon 2017: Kubernetes from Dev to ProdKubeCon 2017: Kubernetes from Dev to Prod
KubeCon 2017: Kubernetes from Dev to Prod
 
Docker Ecosystem on Azure
Docker Ecosystem on AzureDocker Ecosystem on Azure
Docker Ecosystem on Azure
 
Docker Basics
Docker BasicsDocker Basics
Docker Basics
 
Kubernetes - introduction
Kubernetes - introductionKubernetes - introduction
Kubernetes - introduction
 
Building microservices with docker
Building microservices with dockerBuilding microservices with docker
Building microservices with docker
 

Destaque

REST yoluyla Web Servis GeliƟtirme
REST yoluyla Web Servis GeliƟtirmeREST yoluyla Web Servis GeliƟtirme
REST yoluyla Web Servis GeliƟtirme
emirkarsiyakali
 

Destaque (20)

Docker Nedir, Ne İƟe Yarar, Nasıl Kullanılmalıdır?
Docker Nedir, Ne İƟe Yarar, Nasıl Kullanılmalıdır? Docker Nedir, Ne İƟe Yarar, Nasıl Kullanılmalıdır?
Docker Nedir, Ne İƟe Yarar, Nasıl Kullanılmalıdır?
 
Jenkins
JenkinsJenkins
Jenkins
 
ÖzgĂŒr Yazılım ve LINUX
ÖzgĂŒr Yazılım ve LINUXÖzgĂŒr Yazılım ve LINUX
ÖzgĂŒr Yazılım ve LINUX
 
Php1
Php1Php1
Php1
 
PHPkonf'15 - PHP Uygulamanızı GĂŒĂ§lendirin
PHPkonf'15 - PHP Uygulamanızı GĂŒĂ§lendirinPHPkonf'15 - PHP Uygulamanızı GĂŒĂ§lendirin
PHPkonf'15 - PHP Uygulamanızı GĂŒĂ§lendirin
 
Varnish
VarnishVarnish
Varnish
 
Eticaret GĂŒvenliği
Eticaret GĂŒvenliğiEticaret GĂŒvenliği
Eticaret GĂŒvenliği
 
Web Onyuzu Nasil Olmali
Web Onyuzu Nasil OlmaliWeb Onyuzu Nasil Olmali
Web Onyuzu Nasil Olmali
 
Git ile SĂŒrĂŒm Takibi
Git ile SĂŒrĂŒm TakibiGit ile SĂŒrĂŒm Takibi
Git ile SĂŒrĂŒm Takibi
 
Algoritma kurmak
Algoritma kurmakAlgoritma kurmak
Algoritma kurmak
 
PHP Sunusu - 1
PHP Sunusu - 1PHP Sunusu - 1
PHP Sunusu - 1
 
Php mysql sunum
Php mysql sunumPhp mysql sunum
Php mysql sunum
 
ÖzgĂŒr Yazılım & GNU/Linux
ÖzgĂŒr Yazılım & GNU/LinuxÖzgĂŒr Yazılım & GNU/Linux
ÖzgĂŒr Yazılım & GNU/Linux
 
Java script
Java scriptJava script
Java script
 
Php MySQL
Php MySQLPhp MySQL
Php MySQL
 
REST yoluyla Web Servis GeliƟtirme
REST yoluyla Web Servis GeliƟtirmeREST yoluyla Web Servis GeliƟtirme
REST yoluyla Web Servis GeliƟtirme
 
PHPUnit ve Laravel
PHPUnit ve LaravelPHPUnit ve Laravel
PHPUnit ve Laravel
 
Jquery GiriƟ
Jquery GiriƟJquery GiriƟ
Jquery GiriƟ
 
Linux sunum
Linux sunumLinux sunum
Linux sunum
 
Nmap101 Eğitim Sunumu - Nmap Kullanım Kılavuzu
Nmap101 Eğitim Sunumu - Nmap Kullanım KılavuzuNmap101 Eğitim Sunumu - Nmap Kullanım Kılavuzu
Nmap101 Eğitim Sunumu - Nmap Kullanım Kılavuzu
 

Semelhante a Docker - Ankara JUG, Nisan 2015

Evolution of Linux Containerization
Evolution of Linux Containerization Evolution of Linux Containerization
Evolution of Linux Containerization
WSO2
 
Revolutionizing the cloud with container virtualization
Revolutionizing the cloud with container virtualizationRevolutionizing the cloud with container virtualization
Revolutionizing the cloud with container virtualization
WSO2
 
2 Linux Container and Docker
2 Linux Container and Docker2 Linux Container and Docker
2 Linux Container and Docker
Fabio Fumarola
 
Docker - Portable Deployment
Docker - Portable DeploymentDocker - Portable Deployment
Docker - Portable Deployment
javaonfly
 

Semelhante a Docker - Ankara JUG, Nisan 2015 (20)

Linux containers and docker
Linux containers and dockerLinux containers and docker
Linux containers and docker
 
Evolution of Linux Containerization
Evolution of Linux Containerization Evolution of Linux Containerization
Evolution of Linux Containerization
 
Evoluation of Linux Container Virtualization
Evoluation of Linux Container VirtualizationEvoluation of Linux Container Virtualization
Evoluation of Linux Container Virtualization
 
Revolutionizing the cloud with container virtualization
Revolutionizing the cloud with container virtualizationRevolutionizing the cloud with container virtualization
Revolutionizing the cloud with container virtualization
 
Docker on Power Systems
Docker on Power SystemsDocker on Power Systems
Docker on Power Systems
 
Academy PRO: Docker. Part 1
Academy PRO: Docker. Part 1Academy PRO: Docker. Part 1
Academy PRO: Docker. Part 1
 
Docker+java
Docker+javaDocker+java
Docker+java
 
2 Linux Container and Docker
2 Linux Container and Docker2 Linux Container and Docker
2 Linux Container and Docker
 
Develop with linux containers and docker
Develop with linux containers and dockerDevelop with linux containers and docker
Develop with linux containers and docker
 
Evolution of containers to kubernetes
Evolution of containers to kubernetesEvolution of containers to kubernetes
Evolution of containers to kubernetes
 
Docker-Hanoi @DKT , Presentation about Docker Ecosystem
Docker-Hanoi @DKT , Presentation about Docker EcosystemDocker-Hanoi @DKT , Presentation about Docker Ecosystem
Docker-Hanoi @DKT , Presentation about Docker Ecosystem
 
Accelerate your development with Docker
Accelerate your development with DockerAccelerate your development with Docker
Accelerate your development with Docker
 
Accelerate your software development with Docker
Accelerate your software development with DockerAccelerate your software development with Docker
Accelerate your software development with Docker
 
Microservices , Docker , CI/CD , Kubernetes Seminar - Sri Lanka
Microservices , Docker , CI/CD , Kubernetes Seminar - Sri Lanka Microservices , Docker , CI/CD , Kubernetes Seminar - Sri Lanka
Microservices , Docker , CI/CD , Kubernetes Seminar - Sri Lanka
 
An Updated Performance Comparison of Virtual Machines and Linux Containers
An Updated Performance Comparison of Virtual Machines and Linux ContainersAn Updated Performance Comparison of Virtual Machines and Linux Containers
An Updated Performance Comparison of Virtual Machines and Linux Containers
 
Academy PRO: Docker. Lecture 1
Academy PRO: Docker. Lecture 1Academy PRO: Docker. Lecture 1
Academy PRO: Docker. Lecture 1
 
Docker - Portable Deployment
Docker - Portable DeploymentDocker - Portable Deployment
Docker - Portable Deployment
 
docker
dockerdocker
docker
 
Kubernetes
KubernetesKubernetes
Kubernetes
 
Docker dev ops for cd meetup 12-14
Docker dev ops for cd meetup 12-14Docker dev ops for cd meetup 12-14
Docker dev ops for cd meetup 12-14
 

Último

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Último (20)

🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 

Docker - Ankara JUG, Nisan 2015

Notas do Editor

  1. As noted in their website, www.docker.com
  2. Hypervisors: KVM, Xen