SlideShare ist ein Scribd-Unternehmen logo
1 von 29
Immutable Infrastructure
With Docker and EC2
Docker Conf 2014
Michael Bryzek
CTO & Co-Founder Gilt
michael@gilt.com / @mbryzek
http://tech.gilt.com / @gilttech
What is Gilt?
Founded in 2007
World’s best brands and products at 50-70% off
New products launch at noon EST
Limited inventory – products constantly sell out
Over 1000 employees
Gilt Tech
• ~150 people
• Strategy to attract great people and enable
them to innovate
• Lots of Small Teams
• Micro services architecture
• 300+ services
• ~1000 git repos
• Busy days see > 100 production releases
• > 10k requests / second
Immutable Infrastructure Why it Matters
We believe innovation fuels growth.
Part of our strategy to accelerate innovation
Is to create truly autonomous teams
Supported by tooling and automated processes
to relentlessly decrease risk of change
Lots of Small Applications (LOSA)
• Technology Strategy focused on:
• Autonomy
• Decentralization
• Parallelism
• Isolation
Teams and LOSA
• Lots of Small Teams
• 4-10 people / team
• Have all “ingredients” to succeed
• Deliver across stack for most projects
Defining Risk
Move Fast
with
Minimal Risk
What that Actually Means
Defining Risk
Probability (event)
* Cost(event)
* Number of occurrences
There is a risk to doing nothing
Reducing Probability(event)
• Testing
• Manual or Automated
• Prefer automated for long term
• Not making changes
• Peer review
• Kaizen
• Immutability
• Ownership / Pride
• Experience
Reducing Cost(event)
• Small change sets
• Verification in target environment
• Incremental rollout
• Automated rollout / rollback
Reducing NumberOccurrences(event)
• Instant Rollback
• Great Monitoring and Alerting
Modern Software Deployment
1. Foundation of continuous delivery
2. Each deploy immutable
3. Incremental rollout
4. Metrics and alerting
Continuous Delivery @ Gilt Pre Docker
sbt release-remote
1. Build an RPM in Jenkins
2. Deploy RPM to test environment
3. Run unit and integration tests
4. Deploy to one node in production
5. Run healthcheck, auto rollback if necessary
6. Repeat 4-6 on remaining nodes
Continuous Delivery @ Gilt w/ Docker
ionblaster new api 1.2.3
ionblaster traffic api
1.2.2 90
1.2.3 10
1. Build docker container
2. Create new “stack” of infrastructure
3. Run container on each node in stack
4. Assign DNS to new stack
5. Manage traffic from old to new
ionblaster new api 0.4.2
Immutable Infrastructure / Docker
Huge win w/ docker
Dependencies in Dockerfile
Focus instead on cloud and new stacks
Docker and Play Framework
$ sbt stage
$ more api/Dockerfile
FROM giltarchitecture/
ubuntu-openjdk-7-jre-headless:12.0.4
ADD . /apidoc
ENTRYPOINT ["/apidoc/bin/apidoc-api"]
Sample command to start play
container image
-run “
--expose 80
-p 9000:80
giltarchitecture/apidoc-api-1-2-3
–Dhttp.port=90
-Dconfig.resource=xxx.conf
”
Immutability w/ Docker
Immutability emerges naturally when using Docker
Upgrade Java? New version, new infrastructure,
new containers.
Security patch? New version, new infrastructure,
new containers.
Eliminate surprise for application owners.
Automate Incremental Rollout
Core area of focus now
ionroller api 1.2.3 1.2.4 “24 hours”
Measure response time and status codes
- triggers based on tolerance between versions
Instant Rollback
If prior version around – just move traffic
ionblaster traffic api 1.2.3 100
If not, same as before - deploy version
But then can revise garbage collection policy for
the app to decrease risk of a future event. (Kaizen)
Amazing Metrics and Alerting
Reporting and alerting is hard
Used nagios, graphite, open TSDB w/ limited
success.
We are now building a REST API for alerting on top
of influxdb (open source time series db). Plan to
open source if successful.
Lessons Learned: Incremental Rollout
Minimize number of versions in production at any
one time – e.g. “at most 2”
Garbage collection important, but keep prior
versions around for long enough (1 day? 1 week?)
Different apps have different requirements on
rollout time – back to calculation of Risk and the
Cost(event)
Lessons Learned - PAAS
You must have platform as a service; impossible to
build well if not your core business.
It’s tempting to build out a PAAS; but the number
of tools needed to make this work reliably at scale
is large.
Lessons Learned: Alerting
Core interface:
Send me at most one alert every n hours
Core challenge always:
• Signal to noise ratio critical and first class
• Human tendency to ignore over time
Immutable Infra w/ Docker and EC2
• Decrease Probability(Event)
• Immutability
• Decrease Cost(Event)
• Verification in target env w/ no user traffic
• Incremental Rollout
• Automated rollout/rollback
• Reduce NumberOccurrences(event)
• Instant Rollback
Thank You
Michael Bryzek
CTO & Co-Founder Gilt
michael@gilt.com / @mbryzek
http://tech.gilt.com / @gilttech

Weitere ähnliche Inhalte

Was ist angesagt?

Write Once and REALLY Run Anywhere | OpenStack Summit HK 2013
Write Once and REALLY Run Anywhere | OpenStack Summit HK 2013Write Once and REALLY Run Anywhere | OpenStack Summit HK 2013
Write Once and REALLY Run Anywhere | OpenStack Summit HK 2013
dotCloud
 
Introduction to containers running dockers using kubernetes - הרצאה לכנס מיק...
Introduction to containers  running dockers using kubernetes - הרצאה לכנס מיק...Introduction to containers  running dockers using kubernetes - הרצאה לכנס מיק...
Introduction to containers running dockers using kubernetes - הרצאה לכנס מיק...
Zohar Stolar
 
Docker, a new LINUX container technology based light weight virtualization
Docker, a new LINUX container technology based light weight virtualizationDocker, a new LINUX container technology based light weight virtualization
Docker, a new LINUX container technology based light weight virtualization
Suresh Balla
 
Why Docker
Why DockerWhy Docker
Why Docker
dotCloud
 
OpenStack - Docker - Rackspace HQ
OpenStack - Docker - Rackspace HQOpenStack - Docker - Rackspace HQ
OpenStack - Docker - Rackspace HQ
dotCloud
 

Was ist angesagt? (20)

Immutable infrastructure & Micro Services
Immutable infrastructure & Micro ServicesImmutable infrastructure & Micro Services
Immutable infrastructure & Micro Services
 
Introduction to Docker
Introduction to DockerIntroduction to Docker
Introduction to Docker
 
Deploying containers and managing them on multiple Docker hosts, Docker Meetu...
Deploying containers and managing them on multiple Docker hosts, Docker Meetu...Deploying containers and managing them on multiple Docker hosts, Docker Meetu...
Deploying containers and managing them on multiple Docker hosts, Docker Meetu...
 
Building a smarter application Stack by Tomas Doran from Yelp
Building a smarter application Stack by Tomas Doran from YelpBuilding a smarter application Stack by Tomas Doran from Yelp
Building a smarter application Stack by Tomas Doran from Yelp
 
Write Once and REALLY Run Anywhere | OpenStack Summit HK 2013
Write Once and REALLY Run Anywhere | OpenStack Summit HK 2013Write Once and REALLY Run Anywhere | OpenStack Summit HK 2013
Write Once and REALLY Run Anywhere | OpenStack Summit HK 2013
 
DockerCon EU 2015: Speed Up Deployment: Building a Distributed Docker Registr...
DockerCon EU 2015: Speed Up Deployment: Building a Distributed Docker Registr...DockerCon EU 2015: Speed Up Deployment: Building a Distributed Docker Registr...
DockerCon EU 2015: Speed Up Deployment: Building a Distributed Docker Registr...
 
Docker at Spotify - Dockercon14
Docker at Spotify - Dockercon14Docker at Spotify - Dockercon14
Docker at Spotify - Dockercon14
 
Docker and Containers overview - Docker Workshop
Docker and Containers overview - Docker WorkshopDocker and Containers overview - Docker Workshop
Docker and Containers overview - Docker Workshop
 
Introduction to Docker at SF Peninsula Software Development Meetup @Guidewire
Introduction to Docker at SF Peninsula Software Development Meetup @GuidewireIntroduction to Docker at SF Peninsula Software Development Meetup @Guidewire
Introduction to Docker at SF Peninsula Software Development Meetup @Guidewire
 
Dev with Docker WCPHX 2019
Dev with Docker WCPHX 2019Dev with Docker WCPHX 2019
Dev with Docker WCPHX 2019
 
Docker 101 @KACST Saudi HPC 2016
Docker 101  @KACST Saudi HPC 2016Docker 101  @KACST Saudi HPC 2016
Docker 101 @KACST Saudi HPC 2016
 
Introduction to containers running dockers using kubernetes - הרצאה לכנס מיק...
Introduction to containers  running dockers using kubernetes - הרצאה לכנס מיק...Introduction to containers  running dockers using kubernetes - הרצאה לכנס מיק...
Introduction to containers running dockers using kubernetes - הרצאה לכנס מיק...
 
Docker, a new LINUX container technology based light weight virtualization
Docker, a new LINUX container technology based light weight virtualizationDocker, a new LINUX container technology based light weight virtualization
Docker, a new LINUX container technology based light weight virtualization
 
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
 
Why Docker
Why DockerWhy Docker
Why Docker
 
OpenStack - Docker - Rackspace HQ
OpenStack - Docker - Rackspace HQOpenStack - Docker - Rackspace HQ
OpenStack - Docker - Rackspace HQ
 
Dockerize the World - presentation from Hradec Kralove
Dockerize the World - presentation from Hradec KraloveDockerize the World - presentation from Hradec Kralove
Dockerize the World - presentation from Hradec Kralove
 
Docker, the Future of Distributed Applications | Docker Tour de France 2014
Docker, the Future of Distributed Applications | Docker Tour de France 2014Docker, the Future of Distributed Applications | Docker Tour de France 2014
Docker, the Future of Distributed Applications | Docker Tour de France 2014
 
How we dockerized a startup? #meetup #docker
How we dockerized a startup? #meetup #docker How we dockerized a startup? #meetup #docker
How we dockerized a startup? #meetup #docker
 
Docker Overview - Rise of the Containers
Docker Overview - Rise of the ContainersDocker Overview - Rise of the Containers
Docker Overview - Rise of the Containers
 

Andere mochten auch

Docker 101: Introduction to Docker
Docker 101: Introduction to DockerDocker 101: Introduction to Docker
Docker 101: Introduction to Docker
Docker, Inc.
 

Andere mochten auch (6)

Introduction to Docker
Introduction to DockerIntroduction to Docker
Introduction to Docker
 
Docker introduction
Docker introductionDocker introduction
Docker introduction
 
Docker by Example - Basics
Docker by Example - Basics Docker by Example - Basics
Docker by Example - Basics
 
A Gentle Introduction To Docker And All Things Containers
A Gentle Introduction To Docker And All Things ContainersA Gentle Introduction To Docker And All Things Containers
A Gentle Introduction To Docker And All Things Containers
 
Docker 101: Introduction to Docker
Docker 101: Introduction to DockerDocker 101: Introduction to Docker
Docker 101: Introduction to Docker
 
Integrating Docker EE into Société Générale's Existing Enterprise IT Systems
Integrating Docker EE into Société Générale's Existing Enterprise IT SystemsIntegrating Docker EE into Société Générale's Existing Enterprise IT Systems
Integrating Docker EE into Société Générale's Existing Enterprise IT Systems
 

Ähnlich wie Immutable infrastructure with Docker and EC2

Implementing DevOps at Scale Using Dynamic Environments
Implementing DevOps at Scale Using Dynamic EnvironmentsImplementing DevOps at Scale Using Dynamic Environments
Implementing DevOps at Scale Using Dynamic Environments
Sauce Labs
 

Ähnlich wie Immutable infrastructure with Docker and EC2 (20)

Docker Bday #5, SF Edition: Introduction to Docker
Docker Bday #5, SF Edition: Introduction to DockerDocker Bday #5, SF Edition: Introduction to Docker
Docker Bday #5, SF Edition: Introduction to Docker
 
Continuos Integration and Delivery: from Zero to Hero with TeamCity, Docker a...
Continuos Integration and Delivery: from Zero to Hero with TeamCity, Docker a...Continuos Integration and Delivery: from Zero to Hero with TeamCity, Docker a...
Continuos Integration and Delivery: from Zero to Hero with TeamCity, Docker a...
 
Scalable full-stack development at the edge - Pascal Wolkotte - Codemotion Am...
Scalable full-stack development at the edge - Pascal Wolkotte - Codemotion Am...Scalable full-stack development at the edge - Pascal Wolkotte - Codemotion Am...
Scalable full-stack development at the edge - Pascal Wolkotte - Codemotion Am...
 
The DevOps paradigm - the evolution of IT professionals and opensource toolkit
The DevOps paradigm - the evolution of IT professionals and opensource toolkitThe DevOps paradigm - the evolution of IT professionals and opensource toolkit
The DevOps paradigm - the evolution of IT professionals and opensource toolkit
 
The DevOps Paradigm
The DevOps ParadigmThe DevOps Paradigm
The DevOps Paradigm
 
Devops phase-1
Devops phase-1Devops phase-1
Devops phase-1
 
Docker Birthday #5 Meetup Cluj - Presentation
Docker Birthday #5 Meetup Cluj - PresentationDocker Birthday #5 Meetup Cluj - Presentation
Docker Birthday #5 Meetup Cluj - Presentation
 
implanting DevOps at scale using dynamic test environments
implanting DevOps at scale using dynamic test environmentsimplanting DevOps at scale using dynamic test environments
implanting DevOps at scale using dynamic test environments
 
Implementing DevOps at Scale Using Dynamic Environments
Implementing DevOps at Scale Using Dynamic EnvironmentsImplementing DevOps at Scale Using Dynamic Environments
Implementing DevOps at Scale Using Dynamic Environments
 
Docker Enterprise Edition Overview by Steven Thwaites, Technical Solutions En...
Docker Enterprise Edition Overview by Steven Thwaites, Technical Solutions En...Docker Enterprise Edition Overview by Steven Thwaites, Technical Solutions En...
Docker Enterprise Edition Overview by Steven Thwaites, Technical Solutions En...
 
Docker and Cloud - Enables for DevOps - by ACA-IT
Docker and Cloud - Enables for DevOps - by ACA-ITDocker and Cloud - Enables for DevOps - by ACA-IT
Docker and Cloud - Enables for DevOps - by ACA-IT
 
'DOCKER' & CLOUD: ENABLERS For DEVOPS
'DOCKER' & CLOUD:  ENABLERS For DEVOPS'DOCKER' & CLOUD:  ENABLERS For DEVOPS
'DOCKER' & CLOUD: ENABLERS For DEVOPS
 
DockerCon 15 Keynote - Day 2
DockerCon 15 Keynote - Day 2DockerCon 15 Keynote - Day 2
DockerCon 15 Keynote - Day 2
 
DCEU 18: How To Build Your Containerization Strategy
DCEU 18: How To Build Your Containerization StrategyDCEU 18: How To Build Your Containerization Strategy
DCEU 18: How To Build Your Containerization Strategy
 
Red hat cloud platforms
Red hat cloud platformsRed hat cloud platforms
Red hat cloud platforms
 
OpenShift: Devops Made Easy
OpenShift: Devops Made EasyOpenShift: Devops Made Easy
OpenShift: Devops Made Easy
 
Docker Geneva Meetup - Introduction to Docker
Docker Geneva Meetup - Introduction to DockerDocker Geneva Meetup - Introduction to Docker
Docker Geneva Meetup - Introduction to Docker
 
DevOps demystified
DevOps demystifiedDevOps demystified
DevOps demystified
 
Containers Anywhere with OpenShift by Red Hat - Session Sponsored by Red Hat
Containers Anywhere with OpenShift by Red Hat - Session Sponsored by Red HatContainers Anywhere with OpenShift by Red Hat - Session Sponsored by Red Hat
Containers Anywhere with OpenShift by Red Hat - Session Sponsored by Red Hat
 
Orchestrating VM & Container Deployments
Orchestrating VM & Container DeploymentsOrchestrating VM & Container Deployments
Orchestrating VM & Container Deployments
 

Mehr von dotCloud

Wot2013云计算架构师峰会 -陈轶飞2
Wot2013云计算架构师峰会 -陈轶飞2Wot2013云计算架构师峰会 -陈轶飞2
Wot2013云计算架构师峰会 -陈轶飞2
dotCloud
 
Intro Docker october 2013
Intro Docker october 2013Intro Docker october 2013
Intro Docker october 2013
dotCloud
 

Mehr von dotCloud (17)

Wot2013云计算架构师峰会 -陈轶飞2
Wot2013云计算架构师峰会 -陈轶飞2Wot2013云计算架构师峰会 -陈轶飞2
Wot2013云计算架构师峰会 -陈轶飞2
 
Introduction to Docker and all things containers, Docker Meetup at RelateIQ
Introduction to Docker and all things containers, Docker Meetup at RelateIQIntroduction to Docker and all things containers, Docker Meetup at RelateIQ
Introduction to Docker and all things containers, Docker Meetup at RelateIQ
 
Introduction to dockerfile, SF Peninsula Software Development Meetup @Guidewire
Introduction to dockerfile, SF Peninsula Software Development Meetup @Guidewire Introduction to dockerfile, SF Peninsula Software Development Meetup @Guidewire
Introduction to dockerfile, SF Peninsula Software Development Meetup @Guidewire
 
Dockerizing your applications - Docker workshop @Twitter
Dockerizing your applications - Docker workshop @TwitterDockerizing your applications - Docker workshop @Twitter
Dockerizing your applications - Docker workshop @Twitter
 
Introduction to Docker - Docker workshop @Twitter
Introduction to Docker - Docker workshop @TwitterIntroduction to Docker - Docker workshop @Twitter
Introduction to Docker - Docker workshop @Twitter
 
Docker links | Docker workshop #2 at Twitter
Docker links | Docker workshop #2 at TwitterDocker links | Docker workshop #2 at Twitter
Docker links | Docker workshop #2 at Twitter
 
Dockerfile Basics | Docker workshop #2 at twitter, 2013-11-05
Dockerfile Basics | Docker workshop #2 at twitter, 2013-11-05Dockerfile Basics | Docker workshop #2 at twitter, 2013-11-05
Dockerfile Basics | Docker workshop #2 at twitter, 2013-11-05
 
Intro Docker october 2013
Intro Docker october 2013Intro Docker october 2013
Intro Docker october 2013
 
[Open stack] heat + docker
[Open stack] heat + docker[Open stack] heat + docker
[Open stack] heat + docker
 
Dockerizing WordPress
Dockerizing WordPressDockerizing WordPress
Dockerizing WordPress
 
Building images from dockerfiles
Building images from dockerfilesBuilding images from dockerfiles
Building images from dockerfiles
 
Docker at DevTable
Docker at DevTableDocker at DevTable
Docker at DevTable
 
Docker presentation | Paris Docker Meetup
Docker presentation | Paris Docker MeetupDocker presentation | Paris Docker Meetup
Docker presentation | Paris Docker Meetup
 
Lightweight Virtualization with Linux Containers and Docker | YaC 2013
Lightweight Virtualization with Linux Containers and Docker | YaC 2013Lightweight Virtualization with Linux Containers and Docker | YaC 2013
Lightweight Virtualization with Linux Containers and Docker | YaC 2013
 
Installing and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command lineInstalling and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command line
 
LXC, Docker, and the future of software delivery | LinuxCon 2013
LXC, Docker, and the future of software delivery | LinuxCon 2013LXC, Docker, and the future of software delivery | LinuxCon 2013
LXC, Docker, and the future of software delivery | LinuxCon 2013
 
Docker Presentation at the OpenStack Austin Meetup | 2013-09-12
Docker Presentation at the OpenStack Austin Meetup | 2013-09-12Docker Presentation at the OpenStack Austin Meetup | 2013-09-12
Docker Presentation at the OpenStack Austin Meetup | 2013-09-12
 

Kürzlich hochgeladen

+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
Health
 

Kürzlich hochgeladen (16)

Genuine 8617370543 Hot and Beautiful 💕 Etah Escorts call Girls
Genuine 8617370543 Hot and Beautiful 💕 Etah Escorts call GirlsGenuine 8617370543 Hot and Beautiful 💕 Etah Escorts call Girls
Genuine 8617370543 Hot and Beautiful 💕 Etah Escorts call Girls
 
Technical Data | Sig Sauer Easy6 BDX 1-6x24 | Optics Trade
Technical Data | Sig Sauer Easy6 BDX 1-6x24 | Optics TradeTechnical Data | Sig Sauer Easy6 BDX 1-6x24 | Optics Trade
Technical Data | Sig Sauer Easy6 BDX 1-6x24 | Optics Trade
 
Italy vs Albania Italy Euro 2024 squad Luciano Spalletti's full team ahead of...
Italy vs Albania Italy Euro 2024 squad Luciano Spalletti's full team ahead of...Italy vs Albania Italy Euro 2024 squad Luciano Spalletti's full team ahead of...
Italy vs Albania Italy Euro 2024 squad Luciano Spalletti's full team ahead of...
 
Personal Brand Exploration - By Bradley Dennis
Personal Brand Exploration - By Bradley DennisPersonal Brand Exploration - By Bradley Dennis
Personal Brand Exploration - By Bradley Dennis
 
Cricket Api Solution.pdfCricket Api Solution.pdf
Cricket Api Solution.pdfCricket Api Solution.pdfCricket Api Solution.pdfCricket Api Solution.pdf
Cricket Api Solution.pdfCricket Api Solution.pdf
 
JORNADA 6 LIGA MURO 2024TUXTEPECOAXACA.pdf
JORNADA 6 LIGA MURO 2024TUXTEPECOAXACA.pdfJORNADA 6 LIGA MURO 2024TUXTEPECOAXACA.pdf
JORNADA 6 LIGA MURO 2024TUXTEPECOAXACA.pdf
 
Hire 💕 8617370543 Amethi Call Girls Service Call Girls Agency
Hire 💕 8617370543 Amethi Call Girls Service Call Girls AgencyHire 💕 8617370543 Amethi Call Girls Service Call Girls Agency
Hire 💕 8617370543 Amethi Call Girls Service Call Girls Agency
 
Slovenia Vs Serbia Eurovision odds Slovenia have top.docx
Slovenia Vs Serbia Eurovision odds Slovenia have top.docxSlovenia Vs Serbia Eurovision odds Slovenia have top.docx
Slovenia Vs Serbia Eurovision odds Slovenia have top.docx
 
Spain Vs Italy Spain to be banned from participating in Euro 2024.docx
Spain Vs Italy Spain to be banned from participating in Euro 2024.docxSpain Vs Italy Spain to be banned from participating in Euro 2024.docx
Spain Vs Italy Spain to be banned from participating in Euro 2024.docx
 
Belgium Vs Slovakia Belgium at Euro 2024 Teams in group, fixtures, schedule, ...
Belgium Vs Slovakia Belgium at Euro 2024 Teams in group, fixtures, schedule, ...Belgium Vs Slovakia Belgium at Euro 2024 Teams in group, fixtures, schedule, ...
Belgium Vs Slovakia Belgium at Euro 2024 Teams in group, fixtures, schedule, ...
 
Netherlands Players expected to miss UEFA Euro 2024 due to injury.docx
Netherlands Players expected to miss UEFA Euro 2024 due to injury.docxNetherlands Players expected to miss UEFA Euro 2024 due to injury.docx
Netherlands Players expected to miss UEFA Euro 2024 due to injury.docx
 
Unveiling the Mystery of Main Bazar Chart
Unveiling the Mystery of Main Bazar ChartUnveiling the Mystery of Main Bazar Chart
Unveiling the Mystery of Main Bazar Chart
 
Croatia vs Italy Inter Milan Looking to Carry On Success at Euro 2024.pdf
Croatia vs Italy Inter Milan Looking to Carry On Success at Euro 2024.pdfCroatia vs Italy Inter Milan Looking to Carry On Success at Euro 2024.pdf
Croatia vs Italy Inter Milan Looking to Carry On Success at Euro 2024.pdf
 
basketball evolution History Slides.pdf
basketball evolution  History Slides.pdfbasketball evolution  History Slides.pdf
basketball evolution History Slides.pdf
 
Albania Vs Spain South American coaches lead Albania to Euro 2024 spot.docx
Albania Vs Spain South American coaches lead Albania to Euro 2024 spot.docxAlbania Vs Spain South American coaches lead Albania to Euro 2024 spot.docx
Albania Vs Spain South American coaches lead Albania to Euro 2024 spot.docx
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 

Immutable infrastructure with Docker and EC2

  • 1. Immutable Infrastructure With Docker and EC2 Docker Conf 2014 Michael Bryzek CTO & Co-Founder Gilt michael@gilt.com / @mbryzek http://tech.gilt.com / @gilttech
  • 2. What is Gilt? Founded in 2007 World’s best brands and products at 50-70% off New products launch at noon EST Limited inventory – products constantly sell out Over 1000 employees
  • 3. Gilt Tech • ~150 people • Strategy to attract great people and enable them to innovate • Lots of Small Teams • Micro services architecture • 300+ services • ~1000 git repos • Busy days see > 100 production releases • > 10k requests / second
  • 4. Immutable Infrastructure Why it Matters We believe innovation fuels growth. Part of our strategy to accelerate innovation Is to create truly autonomous teams Supported by tooling and automated processes to relentlessly decrease risk of change
  • 5. Lots of Small Applications (LOSA) • Technology Strategy focused on: • Autonomy • Decentralization • Parallelism • Isolation
  • 6. Teams and LOSA • Lots of Small Teams • 4-10 people / team • Have all “ingredients” to succeed • Deliver across stack for most projects
  • 8.
  • 9. Move Fast with Minimal Risk What that Actually Means
  • 10. Defining Risk Probability (event) * Cost(event) * Number of occurrences There is a risk to doing nothing
  • 11. Reducing Probability(event) • Testing • Manual or Automated • Prefer automated for long term • Not making changes • Peer review • Kaizen • Immutability • Ownership / Pride • Experience
  • 12. Reducing Cost(event) • Small change sets • Verification in target environment • Incremental rollout • Automated rollout / rollback
  • 13. Reducing NumberOccurrences(event) • Instant Rollback • Great Monitoring and Alerting
  • 14. Modern Software Deployment 1. Foundation of continuous delivery 2. Each deploy immutable 3. Incremental rollout 4. Metrics and alerting
  • 15. Continuous Delivery @ Gilt Pre Docker sbt release-remote 1. Build an RPM in Jenkins 2. Deploy RPM to test environment 3. Run unit and integration tests 4. Deploy to one node in production 5. Run healthcheck, auto rollback if necessary 6. Repeat 4-6 on remaining nodes
  • 16. Continuous Delivery @ Gilt w/ Docker ionblaster new api 1.2.3 ionblaster traffic api 1.2.2 90 1.2.3 10 1. Build docker container 2. Create new “stack” of infrastructure 3. Run container on each node in stack 4. Assign DNS to new stack 5. Manage traffic from old to new
  • 18. Immutable Infrastructure / Docker Huge win w/ docker Dependencies in Dockerfile Focus instead on cloud and new stacks
  • 19. Docker and Play Framework $ sbt stage $ more api/Dockerfile FROM giltarchitecture/ ubuntu-openjdk-7-jre-headless:12.0.4 ADD . /apidoc ENTRYPOINT ["/apidoc/bin/apidoc-api"]
  • 20. Sample command to start play container image -run “ --expose 80 -p 9000:80 giltarchitecture/apidoc-api-1-2-3 –Dhttp.port=90 -Dconfig.resource=xxx.conf ”
  • 21. Immutability w/ Docker Immutability emerges naturally when using Docker Upgrade Java? New version, new infrastructure, new containers. Security patch? New version, new infrastructure, new containers. Eliminate surprise for application owners.
  • 22. Automate Incremental Rollout Core area of focus now ionroller api 1.2.3 1.2.4 “24 hours” Measure response time and status codes - triggers based on tolerance between versions
  • 23. Instant Rollback If prior version around – just move traffic ionblaster traffic api 1.2.3 100 If not, same as before - deploy version But then can revise garbage collection policy for the app to decrease risk of a future event. (Kaizen)
  • 24. Amazing Metrics and Alerting Reporting and alerting is hard Used nagios, graphite, open TSDB w/ limited success. We are now building a REST API for alerting on top of influxdb (open source time series db). Plan to open source if successful.
  • 25. Lessons Learned: Incremental Rollout Minimize number of versions in production at any one time – e.g. “at most 2” Garbage collection important, but keep prior versions around for long enough (1 day? 1 week?) Different apps have different requirements on rollout time – back to calculation of Risk and the Cost(event)
  • 26. Lessons Learned - PAAS You must have platform as a service; impossible to build well if not your core business. It’s tempting to build out a PAAS; but the number of tools needed to make this work reliably at scale is large.
  • 27. Lessons Learned: Alerting Core interface: Send me at most one alert every n hours Core challenge always: • Signal to noise ratio critical and first class • Human tendency to ignore over time
  • 28. Immutable Infra w/ Docker and EC2 • Decrease Probability(Event) • Immutability • Decrease Cost(Event) • Verification in target env w/ no user traffic • Incremental Rollout • Automated rollout/rollback • Reduce NumberOccurrences(event) • Instant Rollback
  • 29. Thank You Michael Bryzek CTO & Co-Founder Gilt michael@gilt.com / @mbryzek http://tech.gilt.com / @gilttech