Upload
erik-talboom
View
102
Download
0
Embed Size (px)
Citation preview
Docker for developmentWhy and how to use docker for development
Nelis Boucké
+32 486 76 12 71
@nelisboucke
in/nelis
Erik Talboom
+32 498 43 29 67
@talboomerik
in/talboomerik
Content
● Why a session on docker?● What is docker?● Usage during development?● What did we discover?
Demo: Develop a website
Goal: use docker during development of a website
a. Html, php, javascriptb. Use volume to share website content between host and docker
What is docker?
“Docker - build, ship and run any app. Anywhere”
“Docker is a platform for developing, shipping and running applications using container virtualization technology”
“Docker containers wrap up a piece of software in a complete filesystem that contains everything it needs to run: code, runtime, system tools, system libraries – anything you can install on a server. This guarantees that it will always run the same, regardless of the environment it is running in.”
What is docker?“Docker - build, ship and run any app. Anywhere”
“Docker is a platform for developing, shipping and running applications using container virtualization technology”
“Docker containers wrap up a piece of software in a complete filesystem that contains everything it needs to run: code, runtime, system tools, system libraries – anything you can install on a server. This guarantees that it will always run the same, regardless of the environment it is running in.”
What is docker?“Docker - build, ship and run any app. Anywhere”
“Docker is a platform for developing, shipping and running applications using container virtualization technology”
“Docker containers wrap up a piece of software in a complete filesystem that contains everything it needs to run: code, runtime, system tools, system libraries – anything you can install on a server. This guarantees that it will always run the same, regardless of the environment it is running in.”
What are the different components?Docker engine
Docker hub
Docker machine
Docker swarm
Docker compose
Kitematic
What does it mean for development?
● Lightweight● Simple test environment ● One person makes it work
○ All external packages included!
● Different version in parallel
Demo: Java Spring bootstrap
Goal: use docker during development of a java application
a. Databaseb. Building and package your app in docker
What are the different components?Docker engine
Docker hub
Docker machine
Docker swarm
Docker compose
Kitematic
Demo: Microservices
Goal: setup a scalable microservice app
https://github.com/docker/example-voting-app
Imagine: architecture landscape
CRM Billing Finance
Angular app
Market appBPM ServiceMix
Identity
MySql Postgres
Reverse proxy Admin access gatewaySquid
SFTP server
Imagine: scenario to onboard a customer
CRM Billing Finance
Angular app
Market appBPM ServiceMix
Identity
MySql Postgres
Reverse proxy Admin access gatewaySquid
SFTP server
● Lightweight!● Easy test environment with multiple servers!● Real ‘container’
Difference with Vagrant?
● External packages encapsulated (build time of Docker)● Less resources
What does it mean for development?
What are the different components?Docker engine
Docker hub
Docker machine
Docker swarm
Docker compose
Kitematic
What does it mean for development?
● Isolated environments for focused testing● Fast end users testing and feedback!● No need to run complex environment locally
What are the different components?Docker engine
Docker hub
Docker machine
Docker swarm
Docker compose
Kitematic
What does this mean for development?
● Enables mixed technologies● Plays really well with microservices● Higher flexibility
○ Deployment options○ Scaling○ Updates
→ More fundamental shift then some people realise
Docker volumes
“A volume is a designated directory in a container, which is designed to persist data, independent of the container’s lifecycle”
+ Volume changes are excluded when updating an image+ Persist when a container is deleted+ Can be mapped to a host folder+ Can be shared between containers
● Reproducible and reliable● Easy and fast to build, test, release● Potentially shippable product focus
Underlying principles
Challenges introducing docker
● Learning curve for your developers and ops team.○ You really need some Ops knowledge to set this up.
● Not everything is easy to dockerize well (e.g. Jenkins)● Docker for dev != Docker in production● Docker environment is fast changing, and comes with a whole new set of tools● Docker stability in production (disk drivers, network setup, connection with
Kernel)● Docker security?
Thank youNelis Boucke
+32 486 76 12 71
@nelisboucke
in/nelis
Erik Talboom
+32 498 43 29 67
@talboomerik
in/talboomerik