SlideShare uma empresa Scribd logo
1 de 27
Baixar para ler offline
Docker at Lyft
Speeding up development
Matthew Leventi @mleventi #dockercon
Lyft Engineering
Lyft Engineering
Organization
- Rapidly growing headcount
- Fluid teams
- Everyone does devops
Technology
- 50+ microservices
- 25 server deploys a day
- 2 client pushes a week
- Highly available
DockerCon 2015
Systems Engineering
DockerCon 2015
Developer Productivity
- New developers ship on Day 1
- Seamless team switches
- Faster feature development
Operational Stability
- everything must scale
- nothing goes down
Developer Productivity
Inefficiencies Multiply...
DockerCon 2015
General Problems
“It doesn’t work on my box!”
“I don’t understand how the client got into that state!”
“It worked in development!”
“How do I get service X to talk to service Y?”
“How do I test this feature from the client?”
“How do I get started working on a new team?”
DockerCon 2015
Invest in Dev Environments
In the past...
DockerCon 2015
AWS Dev EC2 Instances - 1 per dev per service
NFS syncing for code changes
Service discovery through dev config sections
Manual task to stay up to date on changes
Individual SQS, Dynamo resources per developer
Expensive to orchestrate
Vagrant VM Images
Hard to run more than 2 on a mac
Hard to interface with cloud resources.
Development Environment
Devbox: Everyone has the same
up to date local environment
Onebox: All of lyft, in the cloud,
running any combination of
builds
CI: Cross service integration
testing, deploys
DockerCon 2015
Devbox
Start a set of services easily:
./service start api dispatch eta
Automatically mount repos into services:
ls .
api dispatch eta payments python-sdk
Load and save state snapshots:
./service snap issue519
./service apply issue519
Open websites locally
./service open api
Build new services locally
./service build new_service_X
DockerCon 2015
Onebox
DockerCon 2015
Every QA engineer has their own
environment.
No mocking needed for client
development.
Easy to share state between
developers.
CI
DockerCon 2015
Every service defines test
suites with dependent
services.
Tests are run per pull request
and on master commits.
Isolated cross service
integration tests.
How?
Service Model
- Single fat containers
- Stateless
- Fixed static ip address
- Single “stateful” local
container
- Auto detect code changes
DockerCon 2015
Building a Service Image
- Docker image is a fs snapshot of config management.
- Each image has:
- git clone of a central ops codebase
- git clone of a service codebase
- a salt stack provisioning run.
- runit configuration for processes
ID = $(docker run --env SERVICE=api --env SERVICE_SHA=abc --env OPS_SHA=def lyft/base)
docker commit $ID api
docker push api
No dockerfiles!
DockerCon 2015
Running a Service Image
DockerCon 2015
- Rerun salt provisioning on new SHAs
- Start runit processes
- Terminate the container if initial runit checks fail
Allows
- Developers can easily apply ops modifications
- Testing PRs are a matter of changing env variables
- Don’t need to wait for an image build, deltas are applied during
runtime
- Easy to mount code volumes and trigger changes
Single Host
DockerCon 2015
DevBox
Mac docker host using vmware fusion with shared folders
CI Slave
AWS ubuntu docker host for short lived containers
Onebox
AWS ubuntu docker host for long lived environments
Managing State
DockerCon 2015
All stateful processes run inside the same container.
- Redis
- MongoDB
- DynamoLocal
- SQS Local
- Fake Kinesis
Standard import/export scripts to S3 tar files.
All developers, qa, slaves get their own data environment.
Demo
Results
Results
Productivity
Majority of new hires push to production on day one.
Feature development is no longer blocked by devops.
QA client testing is parallelized.
Stability
99% of deploys are successful.
Every PR on every service is integration tested.
DockerCon 2015
Lessons Learned
Lessons Learned
VMWare Fusion can be unstable under load
Frequent image downloads take time
Bugs in config management can freeze development
Easy service creation leads to unnecessary services
Approach limits on what can run on a single box
Static IP allocation not supported in docker
DockerCon 2015
Future
Future Ideas
Tons of t2.smalls to replace VMWare:
- One container per host in the cloud
- NFSv4 code syncing
- Same static ip private network using libnetwork
- docker-machine
Exploring production docker usage:
- ETL jobs in docker
- Containers to reduce ASG spin up/down times
- Containers for atomic deploys
Thank you
Matthew Leventi
mleventi@lyft.com @mleventi #dockercon

Mais conteúdo relacionado

Mais procurados

Build & Deploy Multi-Container Applications to AWS
Build & Deploy Multi-Container Applications to AWSBuild & Deploy Multi-Container Applications to AWS
Build & Deploy Multi-Container Applications to AWS
Docker, Inc.
 
Containerizing Hardware Accelerated Applications
Containerizing Hardware Accelerated ApplicationsContainerizing Hardware Accelerated Applications
Containerizing Hardware Accelerated Applications
Docker, Inc.
 

Mais procurados (20)

DockerCon EU 2015: Placing a container on a train at 200mph
DockerCon EU 2015: Placing a container on a train at 200mphDockerCon EU 2015: Placing a container on a train at 200mph
DockerCon EU 2015: Placing a container on a train at 200mph
 
Docker Online Meetup: Announcing Docker CE + EE
Docker Online Meetup: Announcing Docker CE + EEDocker Online Meetup: Announcing Docker CE + EE
Docker Online Meetup: Announcing Docker CE + EE
 
Build & Deploy Multi-Container Applications to AWS
Build & Deploy Multi-Container Applications to AWSBuild & Deploy Multi-Container Applications to AWS
Build & Deploy Multi-Container Applications to AWS
 
Docker?!?! But I'm a SysAdmin
Docker?!?! But I'm a SysAdminDocker?!?! But I'm a SysAdmin
Docker?!?! But I'm a SysAdmin
 
DCSF 19 Microservices API: Routing Across Any Infrastructure
DCSF 19 Microservices API: Routing Across Any InfrastructureDCSF 19 Microservices API: Routing Across Any Infrastructure
DCSF 19 Microservices API: Routing Across Any Infrastructure
 
Docker for .NET Developers - Michele Leroux Bustamante, Solliance
Docker for .NET Developers - Michele Leroux Bustamante, SollianceDocker for .NET Developers - Michele Leroux Bustamante, Solliance
Docker for .NET Developers - Michele Leroux Bustamante, Solliance
 
DCSF19 Docker Containers & Java: What I Wish I Had Been Told
DCSF19 Docker Containers & Java: What I Wish I Had Been ToldDCSF19 Docker Containers & Java: What I Wish I Had Been Told
DCSF19 Docker Containers & Java: What I Wish I Had Been Told
 
DCEU 18: Docker Containers in a Serverless World
DCEU 18: Docker Containers in a Serverless WorldDCEU 18: Docker Containers in a Serverless World
DCEU 18: Docker Containers in a Serverless World
 
DCSF19 How To Build Your Containerization Strategy
DCSF19 How To Build Your Containerization Strategy  DCSF19 How To Build Your Containerization Strategy
DCSF19 How To Build Your Containerization Strategy
 
Evénement Docker Paris: Anticipez les nouveaux business model et réduisez vos...
Evénement Docker Paris: Anticipez les nouveaux business model et réduisez vos...Evénement Docker Paris: Anticipez les nouveaux business model et réduisez vos...
Evénement Docker Paris: Anticipez les nouveaux business model et réduisez vos...
 
Containerizing Hardware Accelerated Applications
Containerizing Hardware Accelerated ApplicationsContainerizing Hardware Accelerated Applications
Containerizing Hardware Accelerated Applications
 
DevOps @ OpenShift Online
DevOps @ OpenShift OnlineDevOps @ OpenShift Online
DevOps @ OpenShift Online
 
DCSF 19 Building Your Development Pipeline
DCSF 19 Building Your Development Pipeline  DCSF 19 Building Your Development Pipeline
DCSF 19 Building Your Development Pipeline
 
Java in a world of containers
Java in a world of containersJava in a world of containers
Java in a world of containers
 
Tales of Training: Scaling CodeLabs with Swarm Mode and Docker-Compose
Tales of Training: Scaling CodeLabs with Swarm Mode and Docker-ComposeTales of Training: Scaling CodeLabs with Swarm Mode and Docker-Compose
Tales of Training: Scaling CodeLabs with Swarm Mode and Docker-Compose
 
Considerations for operating docker at scale
Considerations for operating docker at scaleConsiderations for operating docker at scale
Considerations for operating docker at scale
 
An Integrated Pipeline for Private and Public Clouds with Jenkins, Artifactor...
An Integrated Pipeline for Private and Public Clouds with Jenkins, Artifactor...An Integrated Pipeline for Private and Public Clouds with Jenkins, Artifactor...
An Integrated Pipeline for Private and Public Clouds with Jenkins, Artifactor...
 
Automation CI CD with Gitlab, Java, docker on Hidora - Jelastic
Automation CI CD with Gitlab, Java, docker on Hidora - JelasticAutomation CI CD with Gitlab, Java, docker on Hidora - Jelastic
Automation CI CD with Gitlab, Java, docker on Hidora - Jelastic
 
A vision of persistence
A vision of persistenceA vision of persistence
A vision of persistence
 
Modernizing Java Apps with Docker
Modernizing Java Apps with DockerModernizing Java Apps with Docker
Modernizing Java Apps with Docker
 

Destaque

Lyft Company Presentation
Lyft Company PresentationLyft Company Presentation
Lyft Company Presentation
Evan Ward
 
A Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and ContainersA Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and Containers
Docker, Inc.
 

Destaque (20)

DockerCon EU 2015: Day 1 General Session
DockerCon EU 2015: Day 1 General SessionDockerCon EU 2015: Day 1 General Session
DockerCon EU 2015: Day 1 General Session
 
Opening words at DockerCon Europe by Ben Golub
Opening words at DockerCon Europe by Ben Golub Opening words at DockerCon Europe by Ben Golub
Opening words at DockerCon Europe by Ben Golub
 
DockerCon SF 2015: Orchestration for Sysadmins
DockerCon SF 2015: Orchestration for SysadminsDockerCon SF 2015: Orchestration for Sysadmins
DockerCon SF 2015: Orchestration for Sysadmins
 
Docker Hub Breakout Session at DockerCon by Ken Cochrane
Docker Hub Breakout Session at DockerCon by Ken CochraneDocker Hub Breakout Session at DockerCon by Ken Cochrane
Docker Hub Breakout Session at DockerCon by Ken Cochrane
 
DockerCon SF 2015: Keynote Day 1
DockerCon SF 2015: Keynote Day 1DockerCon SF 2015: Keynote Day 1
DockerCon SF 2015: Keynote Day 1
 
DockerCon EU 2015 - The Latest on Docker Engine
DockerCon EU 2015 - The Latest on Docker EngineDockerCon EU 2015 - The Latest on Docker Engine
DockerCon EU 2015 - The Latest on Docker Engine
 
[Team MIAS] Initial Presentation
[Team MIAS] Initial Presentation[Team MIAS] Initial Presentation
[Team MIAS] Initial Presentation
 
Lyft in a New Era of Technology-Enabled Mobility: Implications for Policy and...
Lyft in a New Era of Technology-Enabled Mobility: Implications for Policy and...Lyft in a New Era of Technology-Enabled Mobility: Implications for Policy and...
Lyft in a New Era of Technology-Enabled Mobility: Implications for Policy and...
 
Lyft Company Presentation
Lyft Company PresentationLyft Company Presentation
Lyft Company Presentation
 
Retail Tour Partner Workshop - Zendesk
Retail Tour Partner Workshop - ZendeskRetail Tour Partner Workshop - Zendesk
Retail Tour Partner Workshop - Zendesk
 
ThousandEyes at Zendesk
ThousandEyes at ZendeskThousandEyes at Zendesk
ThousandEyes at Zendesk
 
Lyft Final Presentation
Lyft Final PresentationLyft Final Presentation
Lyft Final Presentation
 
Lyft Company Presentation
Lyft Company PresentationLyft Company Presentation
Lyft Company Presentation
 
Mobycraft - Docker in 8-bit by Aditya Gupta
Mobycraft - Docker in 8-bit by Aditya Gupta Mobycraft - Docker in 8-bit by Aditya Gupta
Mobycraft - Docker in 8-bit by Aditya Gupta
 
OpenStack Summit
OpenStack SummitOpenStack Summit
OpenStack Summit
 
DockerCon EU 2015: Nesting Containers: Real Life Observations
DockerCon EU 2015: Nesting Containers: Real Life ObservationsDockerCon EU 2015: Nesting Containers: Real Life Observations
DockerCon EU 2015: Nesting Containers: Real Life Observations
 
20 mins to Faking the DevOps Unicorn by Matt williams, Datadog
20 mins to Faking the DevOps Unicorn by Matt williams, Datadog20 mins to Faking the DevOps Unicorn by Matt williams, Datadog
20 mins to Faking the DevOps Unicorn by Matt williams, Datadog
 
DockerCon SF 2015: Education for a digital world
DockerCon SF 2015: Education for a digital worldDockerCon SF 2015: Education for a digital world
DockerCon SF 2015: Education for a digital world
 
A Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and ContainersA Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and Containers
 
Docker, Innovation Accelerator
Docker, Innovation AcceleratorDocker, Innovation Accelerator
Docker, Innovation Accelerator
 

Semelhante a DockerCon SF 2015: Docker at Lyft

Was liberty profile and docker
Was liberty profile and dockerWas liberty profile and docker
Was liberty profile and docker
sflynn073
 
Docker intro
Docker introDocker intro
Docker intro
spiddy
 
Docker - Portable Deployment
Docker - Portable DeploymentDocker - Portable Deployment
Docker - Portable Deployment
javaonfly
 

Semelhante a DockerCon SF 2015: Docker at Lyft (20)

Red Hat and kubernetes: awesome stuff coming your way
Red Hat and kubernetes:  awesome stuff coming your wayRed Hat and kubernetes:  awesome stuff coming your way
Red Hat and kubernetes: awesome stuff coming your way
 
Node.js meetup at Palo Alto Networks Tel Aviv
Node.js meetup at Palo Alto Networks Tel AvivNode.js meetup at Palo Alto Networks Tel Aviv
Node.js meetup at Palo Alto Networks Tel Aviv
 
VMworld Europe 2014: A DevOps Story - Unlocking the Power of Docker with the ...
VMworld Europe 2014: A DevOps Story - Unlocking the Power of Docker with the ...VMworld Europe 2014: A DevOps Story - Unlocking the Power of Docker with the ...
VMworld Europe 2014: A DevOps Story - Unlocking the Power of Docker with the ...
 
Cont0519
Cont0519Cont0519
Cont0519
 
Are VMs Passé?
Are VMs Passé?Are VMs Passé?
Are VMs Passé?
 
Are VM Passé?
Are VM Passé? Are VM Passé?
Are VM Passé?
 
WebSphere Application Server Liberty Profile and Docker
WebSphere Application Server Liberty Profile and DockerWebSphere Application Server Liberty Profile and Docker
WebSphere Application Server Liberty Profile and Docker
 
Introduction to Docker - VIT Campus
Introduction to Docker - VIT CampusIntroduction to Docker - VIT Campus
Introduction to Docker - VIT Campus
 
Was liberty profile and docker
Was liberty profile and dockerWas liberty profile and docker
Was liberty profile and docker
 
Introduction to Docker - Vellore Institute of Technology
Introduction to Docker - Vellore Institute of TechnologyIntroduction to Docker - Vellore Institute of Technology
Introduction to Docker - Vellore Institute of Technology
 
DCEU 18: Building Your Development Pipeline
DCEU 18: Building Your Development PipelineDCEU 18: Building Your Development Pipeline
DCEU 18: Building Your Development Pipeline
 
2016 - Easing Your Way Into Docker: Lessons From a Journey to Production
2016 - Easing Your Way Into Docker: Lessons From a Journey to Production2016 - Easing Your Way Into Docker: Lessons From a Journey to Production
2016 - Easing Your Way Into Docker: Lessons From a Journey to Production
 
Develop and deploy Kubernetes applications with Docker - IBM Index 2018
Develop and deploy Kubernetes  applications with Docker - IBM Index 2018Develop and deploy Kubernetes  applications with Docker - IBM Index 2018
Develop and deploy Kubernetes applications with Docker - IBM Index 2018
 
Demystifying Docker101
Demystifying Docker101Demystifying Docker101
Demystifying Docker101
 
Demystifying Docker
Demystifying DockerDemystifying Docker
Demystifying Docker
 
Docker - Demo on PHP Application deployment
Docker - Demo on PHP Application deployment Docker - Demo on PHP Application deployment
Docker - Demo on PHP Application deployment
 
Docker intro
Docker introDocker intro
Docker intro
 
Docker Introduction
Docker IntroductionDocker Introduction
Docker Introduction
 
Docker - Portable Deployment
Docker - Portable DeploymentDocker - Portable Deployment
Docker - Portable Deployment
 
dockerSAW
dockerSAWdockerSAW
dockerSAW
 

Mais de Docker, Inc.

Build & Deploy Multi-Container Applications to AWS
Build & Deploy Multi-Container Applications to AWSBuild & Deploy Multi-Container Applications to AWS
Build & Deploy Multi-Container Applications to AWS
Docker, Inc.
 
Virtual Meetup Docker + Arm: Building Multi-arch Apps with Buildx
Virtual Meetup Docker + Arm: Building Multi-arch Apps with BuildxVirtual Meetup Docker + Arm: Building Multi-arch Apps with Buildx
Virtual Meetup Docker + Arm: Building Multi-arch Apps with Buildx
Docker, Inc.
 

Mais de Docker, Inc. (20)

Containerize Your Game Server for the Best Multiplayer Experience
Containerize Your Game Server for the Best Multiplayer Experience Containerize Your Game Server for the Best Multiplayer Experience
Containerize Your Game Server for the Best Multiplayer Experience
 
How to Improve Your Image Builds Using Advance Docker Build
How to Improve Your Image Builds Using Advance Docker BuildHow to Improve Your Image Builds Using Advance Docker Build
How to Improve Your Image Builds Using Advance Docker Build
 
Build & Deploy Multi-Container Applications to AWS
Build & Deploy Multi-Container Applications to AWSBuild & Deploy Multi-Container Applications to AWS
Build & Deploy Multi-Container Applications to AWS
 
Securing Your Containerized Applications with NGINX
Securing Your Containerized Applications with NGINXSecuring Your Containerized Applications with NGINX
Securing Your Containerized Applications with NGINX
 
How To Build and Run Node Apps with Docker and Compose
How To Build and Run Node Apps with Docker and ComposeHow To Build and Run Node Apps with Docker and Compose
How To Build and Run Node Apps with Docker and Compose
 
Hands-on Helm
Hands-on Helm Hands-on Helm
Hands-on Helm
 
Distributed Deep Learning with Docker at Salesforce
Distributed Deep Learning with Docker at SalesforceDistributed Deep Learning with Docker at Salesforce
Distributed Deep Learning with Docker at Salesforce
 
The First 10M Pulls: Building The Official Curl Image for Docker Hub
The First 10M Pulls: Building The Official Curl Image for Docker HubThe First 10M Pulls: Building The Official Curl Image for Docker Hub
The First 10M Pulls: Building The Official Curl Image for Docker Hub
 
Monitoring in a Microservices World
Monitoring in a Microservices WorldMonitoring in a Microservices World
Monitoring in a Microservices World
 
COVID-19 in Italy: How Docker is Helping the Biggest Italian IT Company Conti...
COVID-19 in Italy: How Docker is Helping the Biggest Italian IT Company Conti...COVID-19 in Italy: How Docker is Helping the Biggest Italian IT Company Conti...
COVID-19 in Italy: How Docker is Helping the Biggest Italian IT Company Conti...
 
Predicting Space Weather with Docker
Predicting Space Weather with DockerPredicting Space Weather with Docker
Predicting Space Weather with Docker
 
Become a Docker Power User With Microsoft Visual Studio Code
Become a Docker Power User With Microsoft Visual Studio CodeBecome a Docker Power User With Microsoft Visual Studio Code
Become a Docker Power User With Microsoft Visual Studio Code
 
How to Use Mirroring and Caching to Optimize your Container Registry
How to Use Mirroring and Caching to Optimize your Container RegistryHow to Use Mirroring and Caching to Optimize your Container Registry
How to Use Mirroring and Caching to Optimize your Container Registry
 
Monolithic to Microservices + Docker = SDLC on Steroids!
Monolithic to Microservices + Docker = SDLC on Steroids!Monolithic to Microservices + Docker = SDLC on Steroids!
Monolithic to Microservices + Docker = SDLC on Steroids!
 
Kubernetes at Datadog Scale
Kubernetes at Datadog ScaleKubernetes at Datadog Scale
Kubernetes at Datadog Scale
 
Labels, Labels, Labels
Labels, Labels, Labels Labels, Labels, Labels
Labels, Labels, Labels
 
From Fortran on the Desktop to Kubernetes in the Cloud: A Windows Migration S...
From Fortran on the Desktop to Kubernetes in the Cloud: A Windows Migration S...From Fortran on the Desktop to Kubernetes in the Cloud: A Windows Migration S...
From Fortran on the Desktop to Kubernetes in the Cloud: A Windows Migration S...
 
Developing with Docker for the Arm Architecture
Developing with Docker for the Arm ArchitectureDeveloping with Docker for the Arm Architecture
Developing with Docker for the Arm Architecture
 
Sharing is Caring: How to Begin Speaking at Conferences
Sharing is Caring: How to Begin Speaking at ConferencesSharing is Caring: How to Begin Speaking at Conferences
Sharing is Caring: How to Begin Speaking at Conferences
 
Virtual Meetup Docker + Arm: Building Multi-arch Apps with Buildx
Virtual Meetup Docker + Arm: Building Multi-arch Apps with BuildxVirtual Meetup Docker + Arm: Building Multi-arch Apps with Buildx
Virtual Meetup Docker + Arm: Building Multi-arch Apps with Buildx
 

Ú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
 

Último (20)

2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
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
 
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
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
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
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
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
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
[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
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
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
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
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
 

DockerCon SF 2015: Docker at Lyft

  • 1. Docker at Lyft Speeding up development Matthew Leventi @mleventi #dockercon
  • 3. Lyft Engineering Organization - Rapidly growing headcount - Fluid teams - Everyone does devops Technology - 50+ microservices - 25 server deploys a day - 2 client pushes a week - Highly available DockerCon 2015
  • 4. Systems Engineering DockerCon 2015 Developer Productivity - New developers ship on Day 1 - Seamless team switches - Faster feature development Operational Stability - everything must scale - nothing goes down
  • 7. General Problems “It doesn’t work on my box!” “I don’t understand how the client got into that state!” “It worked in development!” “How do I get service X to talk to service Y?” “How do I test this feature from the client?” “How do I get started working on a new team?” DockerCon 2015
  • 8. Invest in Dev Environments
  • 9. In the past... DockerCon 2015 AWS Dev EC2 Instances - 1 per dev per service NFS syncing for code changes Service discovery through dev config sections Manual task to stay up to date on changes Individual SQS, Dynamo resources per developer Expensive to orchestrate Vagrant VM Images Hard to run more than 2 on a mac Hard to interface with cloud resources.
  • 10. Development Environment Devbox: Everyone has the same up to date local environment Onebox: All of lyft, in the cloud, running any combination of builds CI: Cross service integration testing, deploys DockerCon 2015
  • 11. Devbox Start a set of services easily: ./service start api dispatch eta Automatically mount repos into services: ls . api dispatch eta payments python-sdk Load and save state snapshots: ./service snap issue519 ./service apply issue519 Open websites locally ./service open api Build new services locally ./service build new_service_X DockerCon 2015
  • 12. Onebox DockerCon 2015 Every QA engineer has their own environment. No mocking needed for client development. Easy to share state between developers.
  • 13. CI DockerCon 2015 Every service defines test suites with dependent services. Tests are run per pull request and on master commits. Isolated cross service integration tests.
  • 14. How?
  • 15. Service Model - Single fat containers - Stateless - Fixed static ip address - Single “stateful” local container - Auto detect code changes DockerCon 2015
  • 16. Building a Service Image - Docker image is a fs snapshot of config management. - Each image has: - git clone of a central ops codebase - git clone of a service codebase - a salt stack provisioning run. - runit configuration for processes ID = $(docker run --env SERVICE=api --env SERVICE_SHA=abc --env OPS_SHA=def lyft/base) docker commit $ID api docker push api No dockerfiles! DockerCon 2015
  • 17. Running a Service Image DockerCon 2015 - Rerun salt provisioning on new SHAs - Start runit processes - Terminate the container if initial runit checks fail Allows - Developers can easily apply ops modifications - Testing PRs are a matter of changing env variables - Don’t need to wait for an image build, deltas are applied during runtime - Easy to mount code volumes and trigger changes
  • 18. Single Host DockerCon 2015 DevBox Mac docker host using vmware fusion with shared folders CI Slave AWS ubuntu docker host for short lived containers Onebox AWS ubuntu docker host for long lived environments
  • 19. Managing State DockerCon 2015 All stateful processes run inside the same container. - Redis - MongoDB - DynamoLocal - SQS Local - Fake Kinesis Standard import/export scripts to S3 tar files. All developers, qa, slaves get their own data environment.
  • 20. Demo
  • 22. Results Productivity Majority of new hires push to production on day one. Feature development is no longer blocked by devops. QA client testing is parallelized. Stability 99% of deploys are successful. Every PR on every service is integration tested. DockerCon 2015
  • 24. Lessons Learned VMWare Fusion can be unstable under load Frequent image downloads take time Bugs in config management can freeze development Easy service creation leads to unnecessary services Approach limits on what can run on a single box Static IP allocation not supported in docker DockerCon 2015
  • 26. Future Ideas Tons of t2.smalls to replace VMWare: - One container per host in the cloud - NFSv4 code syncing - Same static ip private network using libnetwork - docker-machine Exploring production docker usage: - ETL jobs in docker - Containers to reduce ASG spin up/down times - Containers for atomic deploys