This document summarizes Ross Kukulinski's talk on shipping Node.js applications with Docker and CoreOS. The talk covered their company's use of Docker and CoreOS to run Node.js applications, the benefits of Docker and CoreOS, and tips for using Docker registries, developing locally with CoreOS, monitoring, service discovery, and load balancing with CoreOS. Resources for learning more about Docker, CoreOS, and deploying applications with them were also provided.
8. @RossKukulinski
Our Goals
• Reduce application complexity (do one thing well!)
• Scalable
• Fault tolerant
• Support running multiple versions of the same app
• Consistent app from dev → test → staging → prod
• Minimize time spent doing ‘devops’
10. VM vs Docker
@RossKukulinski
https://docker.com/whatisdocker/
11. @RossKukulinski
• Containers start quickly
• Containers have small footprint
• Dockerized applications run anywhere
• Really fast builds via cached images
• Registry for storing images from build pipeline
• Images can be layered
• Abstracts app networking from system networking
12. @RossKukulinski
Our Goals
• Reduce application complexity (do one thing well!)
• Scalable
• Fault tolerant
• Run multiple versions of the same app
• Consistent app from dev → test → staging → prod
• Minimize time spent doing ‘devops’
13. How do you ship
docker containers?
@RossKukulinski
Bash scripts (ugh)
Ansible / Puppet / Chef
15. @RossKukulinski
• Minimal Operating System
• Automated software updates
• Runs docker containers
• Supported by all major cloud
providers
• Can also run on bare metal
https://coreos.com/
16. @RossKukulinski
Fault Tolerant
• Clustered by default
• Support for multiple HA zones
• Distributed tools like etcd & fleet
• HTTP Key-Value Store
• Service Discovery
• Application Scheduling
https://coreos.com/
18. @RossKukulinski
Goals
• Reduce application complexity (do one thing well!)
• Scalable
• Fault tolerant
• Run multiple versions of the same app
• Consistent app from dev → test → staging → prod
• Minimize time spent doing ‘devops’
19. Now for the good stuff
@RossKukulinski
Lessons Learned / Tips & Tricks
20. Docker Registry
@RossKukulinski
• Public Registry
• Private Registry
• Quay.io / DockerHub
• Run your own
• Take advantage of layering docker images
27. Service Discovery
@RossKukulinski
• Don’t hardcode the
host port of your
container
• Sidekick pattern -> Write
to etcd
• Confd (github.com/
kelseyhightower/confd)
• Vulcan
(vulcanproxy.com)
https://coreos.com/
28. Cloud Load Balancers
• How do your users access services in CoreOS?
• Could run Global service with proxy on 80/443
• Or update cloud lbs dynamically based on etcd
• Soon: github.com/astilabs/CoreOS-Cloud-LB
@RossKukulinski
30. Things to watch
@RossKukulinski
• Kubernetes
• Google Container Engine
• Vulcan Proxy
• Paz (paz.sh)
• Panamax (panamax.io)
• Mesosphere (mesosphere.com)
31. @RossKukulinski
Resources
• Example cloud_config
• https://gist.github.com/rosskukulinski/
9ddff8e5f67a24cc7bb7
• Full example of sidekick pattern for Redis
• https://gist.github.com/rosskukulinski/
96f7709fa20d7def6b9e
• PXE Booting CoreOS Post coming soon…
32. Other Resources
@RossKukulinski
• CoreOS Docs: https://coreos.com/docs/
• CoreOS User Google Group
• #coreos & #docker on FreeNode (I’m ‘rossk’)
• SpeakIt GitHub (https://github.com/astilabs)
• SpeakIt Blog (https://blog.speakit.io)