Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Docker at scale with Mesos
Search
Phạm Tuấn Anh
August 27, 2016
Technology
0
150
Docker at scale with Mesos
Phạm Tuấn Anh
August 27, 2016
Tweet
Share
More Decks by Phạm Tuấn Anh
See All by Phạm Tuấn Anh
On building VCCorp Content Delivery Network
andypham
0
76
Infrastructure as Code at VCCorp
andypham
3
460
Other Decks in Technology
See All in Technology
On Your Data を超えていく!
hirotomotaguchi
2
680
Java EE/Jakarta EEの現状と将来―クラウドネイティブ時代にJava EEは対応できるのか?―
takakiyo
1
160
プロトタイピングによる不確実性の低減 / Reducing Uncertainty through Prototyping
ohbarye
5
380
VSCodeの拡張機能を作っている話
ebarakazuhiro
1
390
FrontDoorとWebAppsを組み合わせた際のリダイレクト処理の注意点
kenichirokimura
1
520
Meta Quest 3 で動く桜マシマシ WebXR アプリを IBM Cloud Code Engine と Babylon.js で作った話
1ftseabass
PRO
0
120
VS CodeでAWSを操作しよう
smt7174
8
1.7k
EMとして2023年度に頑張ったこと / What we did well in FY2023 as a EM
pauli
1
170
エンジニア候補者向け資料2024.04.24.pdf
macloud
0
3.3k
Reducing Cross-Zone Egress at Spotify with Custom gRPC Load Balancing Recap
koh_naga
0
200
現代CSSフレームワークの内部実装とその仕組み
poteboy
7
3.6k
いつか使うかも貯金してたらめちゃめちゃ機能が増えてた話
riyaamemiya
0
140
Featured
See All Featured
Building a Scalable Design System with Sketch
lauravandoore
456
32k
For a Future-Friendly Web
brad_frost
172
9k
Build your cross-platform service in a week with App Engine
jlugia
225
17k
The Straight Up "How To Draw Better" Workshop
denniskardys
227
130k
Six Lessons from altMBA
skipperchong
21
3k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
6
1.5k
What’s in a name? Adding method to the madness
productmarketing
PRO
16
2.6k
Designing for humans not robots
tammielis
248
25k
Ruby is Unlike a Banana
tanoku
96
10k
Building Better People: How to give real-time feedback that sticks.
wjessup
355
18k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
60
14k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
125
32k
Transcript
Docker at scale with Mesos Phạm Tuấn Anh Lead engineer
@ VCCloud Platform Services
$ whoami • Lead engineer at VCCloud Platform Services •
Build & work with large-scale/production platform services for about 6 years • Services: Storage, DNS, CDN, DDoS Protection, Logging, Private PaaS
Agenda 1. What is Mesos? 2. How to run docker
containers on Mesos 3. Lessons learned 4. Q&A
1. What is Mesos? 2. How to run docker containers
on Mesos 3. Lessons learned 4. Q&A
None
None
None
None
https://blog.twitter.com/2016/overview-of-the-twitter-cloud-platform-compute
https://mesosphere.com/blog/2015/04/23/apple-details-j-a-r-v-i-s-the-mesos- framework-that-runs-siri/
None
Powered by Mesos: • Apple • Atlassian • CERN •
Cisco • Cloudflare • Foursquare • Groupon • HubSpot • Netflix • Opera • Paypal • Shopee • Shopify • Saleforce • Twitter • Uber • Vimeo • Verizon • Weibo • Yelp • Xiaomi http://mesos.apache.org/documentation/latest/powered-by-mesos/
Solomon Hykes, Founder & CTO of Docker, said at DockerCon
EU 12/2014: Mesos is the “gold standard” for large-scale production clusters running containers
Mesos is: • Open source, top-level Apache project • Proven
at massive scale • Multi-resource (CPU, RAM, Disk, GPU) scheduling • Simplified operational model • Cross platform • Native Docker support
None
None
• PaaS: Marathon, Aurora, Kubernetes, Swarm • Big Data: Hadoop,
Spark, Storm • Database: Cassandra, ArangoDB, • ElasticSearch, Chronos, Jenkins, Kafka… Mesos Frameworks:
1. What is Mesos? 2. How to run docker containers
on Mesos 3. Lessons learned 4. Q&A
• Apache Aurora • Google Kubernetes • HubSpot Singularity •
Mesosphere Marathon
None
None
None
None
None
None
Features: • Start, stop, scale, update, rollback apps • Rolling
deploy / restart • Constraints • Health checks • App dependencies • Highly available, no SPoF
None
None
None
1. What is Mesos? 2. How to run docker containers
on mesos 3. Lessons learned 4. Q&A
– Immutable Infrastructure / CodeShip “Some of the major challenges
today when building infrastructure are predictability, scalability and automated recovery.”
• Container style • Service discovery • Networking Lessons Learned
• Managing secrets • App deployment • Docker annoyances
Choose a container style: • "thin" single-process container • "fat"
container • sshd in container
• Container style • Service discovery • Networking Lessons Learned
• Managing secrets • App deployment • Docker annoyances
Services Discovery • Mesos-DNS: • <app_id>.<app_group>.marathon.mesos • record types: A
/ SRV • simple & stateless
None
• Container style • Service discovery • Networking Lessons Learned
• Managing secrets • App deployment • Docker annoyances
Networking • Project Calico: • IP-per-container • Pure Layer 3
None
None
None
• Container style • Service discovery • Networking Lessons Learned
• Managing secrets • App deployment • Docker annoyances
Managing Secrets • ansible-vault
None
None
None
• Container style • Service discovery • Networking Lessons Learned
• Managing secrets • App deployment • Docker annoyances
App deployment • ansible-playbook • marathon.json • docker tag name
= git commit hash • 1 mesos cluster (3 VMs) per dev • deploy to servers → deploy to marathon
None
marathon.json
None
None
None
None
None
None
None
None
https://flask-hello.marathon.mesos.vn/
Monitoring • Container’s RAM used
Stateful Containers • Local persistent volumes
• Container style • Service discovery • Networking Lessons Learned
• Managing secrets • App deployment • Docker annoyances
Docker • restart / upgrade docker without stopping the running
containers • old images / tags cleanup • container’s stdout / stderr log files • docker pull • docker hub
"Normal" container vs cloud-native container: • No manual steps •
Service discovery friendly • Config files should be optional • Using env vars for config
1. What is Mesos? 2. How to run docker containers
on Mesos 3. Lessons learned 4. Q&A
None
Links • Mesos: http://mesos.apache.org/ • Marathon: https://mesosphere.github.io/marathon/ • Project Calico:
https://www.projectcalico.org/ • Mesos-DNS: https://github.com/mesosphere/mesos-dns • A Healthy Platform Checklist: https://gist.github.com/andy-pham/ 04dedff872b33c07a31277afb900950b