SlideShare a Scribd company logo
Immutable Infrastructure Isn’t the Answer
Sam Bashton
Who am I?
• Sam Bashton
• Ran a cloud (AWS + GCP) consultancy firm until 2016
when it was acquired by Claranet Group
• Working with config management (Puppet) since 2007
• Working with AWS since 2009
• Working with GCP since 2014
What is this talk about?
• How we tried to use immutable infrastructure
• How and why it wasn’t right for us
• What we do instead
Business Model
• Charge customer for building super reliable infrastructure
• Charge customers a monthly support fee
Hard won experience
• Migrated over 1000 apps to public cloud
• Variety of approaches to managing infra and deploying
code
- Including Immutable Infrastructure
• 2011 onwards
Terraform
AWS Concepts
• Each customer in one or more region
• Each region has two or more data centres (‘availability
zones’)
- Most have three
• SLA says that no more than one data centre will be down
at once in a region
“Region Unavailable” and “Region Unavailability” mean that more than one Availability Zone in
which you are running an instance or task (one or more containers), as applicable, within the same
Region, is “Unavailable” to you.
Data Lives in Services
• We use AWS services to store all state
- RDS (MySQL, Postgres, Oracle, MS SQL)
- Elasticache (Redis)
- DynamoDB
- AWS Elasticsearch
• The instances in question are ‘stateless’
Immutable
immutable
/ɪˈmjuːtəb(ə)l/
unchanging over time or unable to be
changed
What is immutable infrastructure?
• Automatically build a golden image
• New infrastructure using the new image replaces the old
infrastructure
Why would I want to do that?
• Unit of deployment becomes a machine image
• Test the artifact and have confidence it’ll be the same in
production
Blue/Green Deployments
Canary Deployments
Fudgetown
• All the images are the same, except..
- We need to specify a different database location in each environment
• And we need to specify it in an XML config file
- We have different sizes of machine in each environment, and need to using
different JVM settings
Why not just build lots of images?
• Image building is automatic - why don’t we just build an
image for each environment?
Why not just build lots of images?
• Unit of deploy is a machine
image
• Images are created via an
imperative set of
commands
- Shell Script
- Ansible
• What is in each image?
What is different?
Immutable-ish
• Scripts at startup handle differences
• Consul cluster?
- consul-template
Fudgetown
Fudgetown
• Many dozens of microservices
• All with configuration files
- XML, yaml, ini, other
Fudgetown
• Multiple processes make up a single ‘service’
• All have to be started in a specific order
Fudgetown
• Deploying changes takes much longer
- ~10-15 minutes for a Packer build and deployment to test infra
• Tests on minor changes take a lot longer
Fudgetown
• We don’t know what the
state of our instances is,
or should be
• We don’t know whether
config files were written
successfully
• It takes ages to test
things
Back to the drawing board
• Doing the thing the ‘cool kids’ say they are doing is not
the path to technical success
• Our customers care whether their app is working, not how
What do we actually need?
• Infrastructure and configuration in a known and verifiable
state
• Self-healing
• Fault tolerant - should continue to work even if a whole
data centre (‘AZ’) fails
• Autoscaling which works every time
• New instances which provision quickly (autoscaling)
• Automated deployments
- Possibly Canary, Blue/Green
• Nice to have: quick to test changes
What do we actually need?
Instance configuration in a known state
• We need a way to describe configuration on the machine
• A declarative language
• Should tell us if something went wrong
Except..
• Puppet master doesn’t lend itself to an autoscaling world
- Performance bottleneck bringing up new instances
- Single point of failure
- Especially in the zone failure scenario
The rules
• Terminating an instance should always automatically give
you a replacement which works
- Even if external repos are down
• CentOS mirrors
• EPEL
• Elasticsearch yum repo
• Gem
• Pip
• We should expect data centre (‘AZ’) failure
How do we do it?
• Packer - base common AMI
• Puppet
• S3
• yum/apt
• Jenkins
Jenkins
Packer
• Build a base image
• Generally common to all roles
• Sometimes will have per-role AMIs
• pip/gem dependencies generally installed here
- Easier than building a package, even with FPM
• Install big RPMs here to save time at provisioning
Masterless Puppet
• Put the Puppet manifests and modules on an instance
• Run puppet apply
Distributing Puppet
• Puppet needs to be on every instance
• Build an RPM/DEB containing Puppet manifests/modules
• Add to a RPM/DEB repo in S3
• Script at startup (cloud-init) installs Puppet
• Puppet runs from systemd❤
External Repos
• Mirror CentOS, etc repos in S3
• Repos are copied as part of deployment process
- Dev repos continually updated
- When code is promoted to next step (eg staging), repos also copied
- OS upgrades are a part of the normal deployment process
Repos in S3
• Puppet, application code
in yum repos in S3
• Repo created from a
Terraform module
• Just drop your RPM in, it
handles metadata
generation
https://registry.terraform.io/
modules/claranet/s3-yum-
repo/aws
Config updates
• AWS provides SSM
• SSM triggers updating Puppet RPM, running Puppet
• ~120 seconds from commit to Puppet run finishing
Success
• We have been using this approach for 6+ years
• Tried other approaches
• Always came back for apps unsuitable for containerisation
Your problems are not my problems
• Have lovely 12 factor apps?
• Why are you wasting time building infrastructure?!
Career advice
• You don’t get paid to build infrastructure
• ‘Serverless’ isn’t NoOps
• Understanding distributed systems and their many failure
modes the path to future success
Conclusions
• Concentrate on the desired outcome, not what somebody
at a conference said worked for them
• Find the things that will give you the most success most
easily, then iterate
• Architect for ease of management
• Don’t be constrained by ‘best practice’
• Don’t be embarrassed by ‘ugly hacks’ when they solve real
problems
Conclusions

More Related Content

What's hot

Infrastructure as Code - Getting Started, Concepts & Tools
Infrastructure as Code - Getting Started, Concepts & ToolsInfrastructure as Code - Getting Started, Concepts & Tools
Infrastructure as Code - Getting Started, Concepts & Tools
Lior Kamrat
 
Manage your environment with DSC
Manage your environment with DSCManage your environment with DSC
Manage your environment with DSC
Gian Maria Ricci
 
EDB Failover Manager for Seamless Failover & Switchover
EDB Failover Manager for Seamless Failover & SwitchoverEDB Failover Manager for Seamless Failover & Switchover
EDB Failover Manager for Seamless Failover & Switchover
Ashnikbiz
 
Immutable infrastructure with Boxfuse
Immutable infrastructure with BoxfuseImmutable infrastructure with Boxfuse
Immutable infrastructure with Boxfuse
Lars Östling
 
Extending Ansible - Ansible Benelux meetup - Amsterdam 11-02-2016
Extending Ansible - Ansible Benelux meetup - Amsterdam 11-02-2016Extending Ansible - Ansible Benelux meetup - Amsterdam 11-02-2016
Extending Ansible - Ansible Benelux meetup - Amsterdam 11-02-2016
Pavel Chunyayev
 
Apple M1 & Ionic: Should I switch?
Apple M1 & Ionic: Should I switch?Apple M1 & Ionic: Should I switch?
Apple M1 & Ionic: Should I switch?
Philipp Höhne
 
Benchmarking like a pro
Benchmarking like a proBenchmarking like a pro
Benchmarking like a pro
Gianluca Sartori
 
Ansible benelux meetup - Amsterdam 27-5-2015
Ansible benelux meetup - Amsterdam 27-5-2015Ansible benelux meetup - Amsterdam 27-5-2015
Ansible benelux meetup - Amsterdam 27-5-2015
Pavel Chunyayev
 
Standardizing and Managing Your Infrastructure - MOSC 2011
Standardizing and Managing Your Infrastructure - MOSC 2011Standardizing and Managing Your Infrastructure - MOSC 2011
Standardizing and Managing Your Infrastructure - MOSC 2011
Brian Ritchie
 
Puppet camp LA and Phoenix 2015: Keynote
Puppet camp LA and Phoenix 2015: Keynote Puppet camp LA and Phoenix 2015: Keynote
Puppet camp LA and Phoenix 2015: Keynote
Puppet
 
Openstack hk-summit-upgrades-talk
Openstack hk-summit-upgrades-talkOpenstack hk-summit-upgrades-talk
Openstack hk-summit-upgrades-talk
Buvanesh Kumar
 
JAMF User Group September 2015
JAMF User Group September 2015JAMF User Group September 2015
JAMF User Group September 2015
Steve Wood
 
NDev Talk - Serverless Design Patterns
NDev Talk - Serverless Design PatternsNDev Talk - Serverless Design Patterns
NDev Talk - Serverless Design Patterns
Ryan Green
 
Building a PaaS with Docker and AWS
Building a PaaS with Docker and AWSBuilding a PaaS with Docker and AWS
Building a PaaS with Docker and AWS
vesirin
 
UEMB260: Provisioning: Under the Hood
UEMB260: Provisioning: Under the HoodUEMB260: Provisioning: Under the Hood
UEMB260: Provisioning: Under the Hood
Ivanti
 
Inrastructure as Code
Inrastructure as CodeInrastructure as Code
Inrastructure as Code
Charles Anderson
 
Building Creative Product Extensions with Experience Manager
Building Creative Product Extensions with Experience ManagerBuilding Creative Product Extensions with Experience Manager
Building Creative Product Extensions with Experience Manager
connectwebex
 
You don’t need DTAP + Backbase implementation - Amsterdam 17-12-2015
You don’t need DTAP + Backbase implementation - Amsterdam 17-12-2015You don’t need DTAP + Backbase implementation - Amsterdam 17-12-2015
You don’t need DTAP + Backbase implementation - Amsterdam 17-12-2015
Pavel Chunyayev
 
Ansible training | redhat Ansible 2.5 Corporate course - GOT
Ansible training | redhat Ansible 2.5 Corporate course - GOTAnsible training | redhat Ansible 2.5 Corporate course - GOT
Ansible training | redhat Ansible 2.5 Corporate course - GOT
keerthi124
 
High performance in react native
High performance in react nativeHigh performance in react native
High performance in react native
Viet Tran
 

What's hot (20)

Infrastructure as Code - Getting Started, Concepts & Tools
Infrastructure as Code - Getting Started, Concepts & ToolsInfrastructure as Code - Getting Started, Concepts & Tools
Infrastructure as Code - Getting Started, Concepts & Tools
 
Manage your environment with DSC
Manage your environment with DSCManage your environment with DSC
Manage your environment with DSC
 
EDB Failover Manager for Seamless Failover & Switchover
EDB Failover Manager for Seamless Failover & SwitchoverEDB Failover Manager for Seamless Failover & Switchover
EDB Failover Manager for Seamless Failover & Switchover
 
Immutable infrastructure with Boxfuse
Immutable infrastructure with BoxfuseImmutable infrastructure with Boxfuse
Immutable infrastructure with Boxfuse
 
Extending Ansible - Ansible Benelux meetup - Amsterdam 11-02-2016
Extending Ansible - Ansible Benelux meetup - Amsterdam 11-02-2016Extending Ansible - Ansible Benelux meetup - Amsterdam 11-02-2016
Extending Ansible - Ansible Benelux meetup - Amsterdam 11-02-2016
 
Apple M1 & Ionic: Should I switch?
Apple M1 & Ionic: Should I switch?Apple M1 & Ionic: Should I switch?
Apple M1 & Ionic: Should I switch?
 
Benchmarking like a pro
Benchmarking like a proBenchmarking like a pro
Benchmarking like a pro
 
Ansible benelux meetup - Amsterdam 27-5-2015
Ansible benelux meetup - Amsterdam 27-5-2015Ansible benelux meetup - Amsterdam 27-5-2015
Ansible benelux meetup - Amsterdam 27-5-2015
 
Standardizing and Managing Your Infrastructure - MOSC 2011
Standardizing and Managing Your Infrastructure - MOSC 2011Standardizing and Managing Your Infrastructure - MOSC 2011
Standardizing and Managing Your Infrastructure - MOSC 2011
 
Puppet camp LA and Phoenix 2015: Keynote
Puppet camp LA and Phoenix 2015: Keynote Puppet camp LA and Phoenix 2015: Keynote
Puppet camp LA and Phoenix 2015: Keynote
 
Openstack hk-summit-upgrades-talk
Openstack hk-summit-upgrades-talkOpenstack hk-summit-upgrades-talk
Openstack hk-summit-upgrades-talk
 
JAMF User Group September 2015
JAMF User Group September 2015JAMF User Group September 2015
JAMF User Group September 2015
 
NDev Talk - Serverless Design Patterns
NDev Talk - Serverless Design PatternsNDev Talk - Serverless Design Patterns
NDev Talk - Serverless Design Patterns
 
Building a PaaS with Docker and AWS
Building a PaaS with Docker and AWSBuilding a PaaS with Docker and AWS
Building a PaaS with Docker and AWS
 
UEMB260: Provisioning: Under the Hood
UEMB260: Provisioning: Under the HoodUEMB260: Provisioning: Under the Hood
UEMB260: Provisioning: Under the Hood
 
Inrastructure as Code
Inrastructure as CodeInrastructure as Code
Inrastructure as Code
 
Building Creative Product Extensions with Experience Manager
Building Creative Product Extensions with Experience ManagerBuilding Creative Product Extensions with Experience Manager
Building Creative Product Extensions with Experience Manager
 
You don’t need DTAP + Backbase implementation - Amsterdam 17-12-2015
You don’t need DTAP + Backbase implementation - Amsterdam 17-12-2015You don’t need DTAP + Backbase implementation - Amsterdam 17-12-2015
You don’t need DTAP + Backbase implementation - Amsterdam 17-12-2015
 
Ansible training | redhat Ansible 2.5 Corporate course - GOT
Ansible training | redhat Ansible 2.5 Corporate course - GOTAnsible training | redhat Ansible 2.5 Corporate course - GOT
Ansible training | redhat Ansible 2.5 Corporate course - GOT
 
High performance in react native
High performance in react nativeHigh performance in react native
High performance in react native
 

Similar to Immutable infrastructure isn’t the answer

Continuous Deployment of your Application - SpringOne Tour Dallas
Continuous Deployment of your Application - SpringOne Tour DallasContinuous Deployment of your Application - SpringOne Tour Dallas
Continuous Deployment of your Application - SpringOne Tour Dallas
VMware Tanzu
 
The Rocky Cloud Road
The Rocky Cloud RoadThe Rocky Cloud Road
The Rocky Cloud Road
Gert Drapers
 
Getting to Walk with DevOps
Getting to Walk with DevOpsGetting to Walk with DevOps
Getting to Walk with DevOps
Eklove Mohan
 
Configuration Management in the Cloud | AWS Public Sector Summit 2017
Configuration Management in the Cloud | AWS Public Sector Summit 2017Configuration Management in the Cloud | AWS Public Sector Summit 2017
Configuration Management in the Cloud | AWS Public Sector Summit 2017
Amazon Web Services
 
Google Cloud Platform Certification Cloud Architect Exam Prep Review Virtual ...
Google Cloud Platform Certification Cloud Architect Exam Prep Review Virtual ...Google Cloud Platform Certification Cloud Architect Exam Prep Review Virtual ...
Google Cloud Platform Certification Cloud Architect Exam Prep Review Virtual ...
Joseph Holbrook, Chief Learning Officer (CLO)
 
PuppetConf 2017: Unlocking Azure with Puppet Enterprise- Keiran Sweet, Source...
PuppetConf 2017: Unlocking Azure with Puppet Enterprise- Keiran Sweet, Source...PuppetConf 2017: Unlocking Azure with Puppet Enterprise- Keiran Sweet, Source...
PuppetConf 2017: Unlocking Azure with Puppet Enterprise- Keiran Sweet, Source...
Puppet
 
Cloud-Native DevOps: Simplifying application lifecycle management with AWS | ...
Cloud-Native DevOps: Simplifying application lifecycle management with AWS | ...Cloud-Native DevOps: Simplifying application lifecycle management with AWS | ...
Cloud-Native DevOps: Simplifying application lifecycle management with AWS | ...
Amazon Web Services
 
How Percolate uses CFEngine to Manage AWS Stateless Infrastructure
How Percolate uses CFEngine to Manage AWS Stateless InfrastructureHow Percolate uses CFEngine to Manage AWS Stateless Infrastructure
How Percolate uses CFEngine to Manage AWS Stateless Infrastructure
Percolate
 
The Hard Problems of Continuous Deployment
The Hard Problems of Continuous DeploymentThe Hard Problems of Continuous Deployment
The Hard Problems of Continuous Deployment
Timothy Fitz
 
DevOps: Automate all the things
DevOps: Automate all the thingsDevOps: Automate all the things
DevOps: Automate all the things
Mat Mannion
 
SynapseIndia drupal presentation on drupal info
SynapseIndia drupal  presentation on drupal infoSynapseIndia drupal  presentation on drupal info
SynapseIndia drupal presentation on drupal info
Synapseindiappsdevelopment
 
DCRUG: Achieving Development-Production Parity
DCRUG: Achieving Development-Production ParityDCRUG: Achieving Development-Production Parity
DCRUG: Achieving Development-Production Parity
Geoff Harcourt
 
DevOps, A brief introduction to Vagrant & Ansible
DevOps, A brief introduction to Vagrant & AnsibleDevOps, A brief introduction to Vagrant & Ansible
DevOps, A brief introduction to Vagrant & Ansible
Arnaud LEMAIRE
 
Continuous Delivery with NetflixOSS
Continuous Delivery with NetflixOSSContinuous Delivery with NetflixOSS
Continuous Delivery with NetflixOSS
Daniel Woods
 
Cloudy in Indonesia: Java and Cloud
Cloudy in Indonesia: Java and CloudCloudy in Indonesia: Java and Cloud
Cloudy in Indonesia: Java and Cloud
Eberhard Wolff
 
Ansible: How to Get More Sleep and Require Less Coffee
Ansible: How to Get More Sleep and Require Less CoffeeAnsible: How to Get More Sleep and Require Less Coffee
Ansible: How to Get More Sleep and Require Less Coffee
Sarah Z
 
Mtc learnings from isv & enterprise interaction
Mtc learnings from isv & enterprise  interactionMtc learnings from isv & enterprise  interaction
Mtc learnings from isv & enterprise interaction
Govind Kanshi
 
Mtc learnings from isv & enterprise (dated - Dec -2014)
Mtc learnings from isv & enterprise (dated - Dec -2014)Mtc learnings from isv & enterprise (dated - Dec -2014)
Mtc learnings from isv & enterprise (dated - Dec -2014)
Govind Kanshi
 
PowerPoint Presentation
PowerPoint PresentationPowerPoint Presentation
PowerPoint Presentation
lalitjangra9
 
Moving Windows Applications to the Cloud
Moving Windows Applications to the CloudMoving Windows Applications to the Cloud
Moving Windows Applications to the Cloud
RightScale
 

Similar to Immutable infrastructure isn’t the answer (20)

Continuous Deployment of your Application - SpringOne Tour Dallas
Continuous Deployment of your Application - SpringOne Tour DallasContinuous Deployment of your Application - SpringOne Tour Dallas
Continuous Deployment of your Application - SpringOne Tour Dallas
 
The Rocky Cloud Road
The Rocky Cloud RoadThe Rocky Cloud Road
The Rocky Cloud Road
 
Getting to Walk with DevOps
Getting to Walk with DevOpsGetting to Walk with DevOps
Getting to Walk with DevOps
 
Configuration Management in the Cloud | AWS Public Sector Summit 2017
Configuration Management in the Cloud | AWS Public Sector Summit 2017Configuration Management in the Cloud | AWS Public Sector Summit 2017
Configuration Management in the Cloud | AWS Public Sector Summit 2017
 
Google Cloud Platform Certification Cloud Architect Exam Prep Review Virtual ...
Google Cloud Platform Certification Cloud Architect Exam Prep Review Virtual ...Google Cloud Platform Certification Cloud Architect Exam Prep Review Virtual ...
Google Cloud Platform Certification Cloud Architect Exam Prep Review Virtual ...
 
PuppetConf 2017: Unlocking Azure with Puppet Enterprise- Keiran Sweet, Source...
PuppetConf 2017: Unlocking Azure with Puppet Enterprise- Keiran Sweet, Source...PuppetConf 2017: Unlocking Azure with Puppet Enterprise- Keiran Sweet, Source...
PuppetConf 2017: Unlocking Azure with Puppet Enterprise- Keiran Sweet, Source...
 
Cloud-Native DevOps: Simplifying application lifecycle management with AWS | ...
Cloud-Native DevOps: Simplifying application lifecycle management with AWS | ...Cloud-Native DevOps: Simplifying application lifecycle management with AWS | ...
Cloud-Native DevOps: Simplifying application lifecycle management with AWS | ...
 
How Percolate uses CFEngine to Manage AWS Stateless Infrastructure
How Percolate uses CFEngine to Manage AWS Stateless InfrastructureHow Percolate uses CFEngine to Manage AWS Stateless Infrastructure
How Percolate uses CFEngine to Manage AWS Stateless Infrastructure
 
The Hard Problems of Continuous Deployment
The Hard Problems of Continuous DeploymentThe Hard Problems of Continuous Deployment
The Hard Problems of Continuous Deployment
 
DevOps: Automate all the things
DevOps: Automate all the thingsDevOps: Automate all the things
DevOps: Automate all the things
 
SynapseIndia drupal presentation on drupal info
SynapseIndia drupal  presentation on drupal infoSynapseIndia drupal  presentation on drupal info
SynapseIndia drupal presentation on drupal info
 
DCRUG: Achieving Development-Production Parity
DCRUG: Achieving Development-Production ParityDCRUG: Achieving Development-Production Parity
DCRUG: Achieving Development-Production Parity
 
DevOps, A brief introduction to Vagrant & Ansible
DevOps, A brief introduction to Vagrant & AnsibleDevOps, A brief introduction to Vagrant & Ansible
DevOps, A brief introduction to Vagrant & Ansible
 
Continuous Delivery with NetflixOSS
Continuous Delivery with NetflixOSSContinuous Delivery with NetflixOSS
Continuous Delivery with NetflixOSS
 
Cloudy in Indonesia: Java and Cloud
Cloudy in Indonesia: Java and CloudCloudy in Indonesia: Java and Cloud
Cloudy in Indonesia: Java and Cloud
 
Ansible: How to Get More Sleep and Require Less Coffee
Ansible: How to Get More Sleep and Require Less CoffeeAnsible: How to Get More Sleep and Require Less Coffee
Ansible: How to Get More Sleep and Require Less Coffee
 
Mtc learnings from isv & enterprise interaction
Mtc learnings from isv & enterprise  interactionMtc learnings from isv & enterprise  interaction
Mtc learnings from isv & enterprise interaction
 
Mtc learnings from isv & enterprise (dated - Dec -2014)
Mtc learnings from isv & enterprise (dated - Dec -2014)Mtc learnings from isv & enterprise (dated - Dec -2014)
Mtc learnings from isv & enterprise (dated - Dec -2014)
 
PowerPoint Presentation
PowerPoint PresentationPowerPoint Presentation
PowerPoint Presentation
 
Moving Windows Applications to the Cloud
Moving Windows Applications to the CloudMoving Windows Applications to the Cloud
Moving Windows Applications to the Cloud
 

Recently uploaded

Infrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI modelsInfrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI models
Zilliz
 
How to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For FlutterHow to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For Flutter
Daiki Mogmet Ito
 
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdfUnlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Malak Abu Hammad
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
Matthew Sinclair
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
SOFTTECHHUB
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
mikeeftimakis1
 
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
Neo4j
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems S.M.S.A.
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
shyamraj55
 
TrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy SurveyTrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy Survey
TrustArc
 
RESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for studentsRESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for students
KAMESHS29
 
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Speck&Tech
 
“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”
Claudio Di Ciccio
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
Tomaz Bratanic
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
Neo4j
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
panagenda
 
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
SOFTTECHHUB
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
panagenda
 
Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
Octavian Nadolu
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
Quotidiano Piemontese
 

Recently uploaded (20)

Infrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI modelsInfrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI models
 
How to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For FlutterHow to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For Flutter
 
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdfUnlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
 
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
 
TrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy SurveyTrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy Survey
 
RESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for studentsRESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for students
 
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
 
“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
 
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
 
Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
 

Immutable infrastructure isn’t the answer

  • 1. Immutable Infrastructure Isn’t the Answer Sam Bashton
  • 2.
  • 3. Who am I? • Sam Bashton • Ran a cloud (AWS + GCP) consultancy firm until 2016 when it was acquired by Claranet Group • Working with config management (Puppet) since 2007 • Working with AWS since 2009 • Working with GCP since 2014
  • 4.
  • 5. What is this talk about? • How we tried to use immutable infrastructure • How and why it wasn’t right for us • What we do instead
  • 6. Business Model • Charge customer for building super reliable infrastructure • Charge customers a monthly support fee
  • 7. Hard won experience • Migrated over 1000 apps to public cloud • Variety of approaches to managing infra and deploying code - Including Immutable Infrastructure • 2011 onwards
  • 8.
  • 9.
  • 10.
  • 12. AWS Concepts • Each customer in one or more region • Each region has two or more data centres (‘availability zones’) - Most have three • SLA says that no more than one data centre will be down at once in a region “Region Unavailable” and “Region Unavailability” mean that more than one Availability Zone in which you are running an instance or task (one or more containers), as applicable, within the same Region, is “Unavailable” to you.
  • 13. Data Lives in Services • We use AWS services to store all state - RDS (MySQL, Postgres, Oracle, MS SQL) - Elasticache (Redis) - DynamoDB - AWS Elasticsearch • The instances in question are ‘stateless’
  • 14.
  • 16. What is immutable infrastructure? • Automatically build a golden image • New infrastructure using the new image replaces the old infrastructure
  • 17. Why would I want to do that? • Unit of deployment becomes a machine image • Test the artifact and have confidence it’ll be the same in production
  • 20. Fudgetown • All the images are the same, except.. - We need to specify a different database location in each environment • And we need to specify it in an XML config file - We have different sizes of machine in each environment, and need to using different JVM settings
  • 21. Why not just build lots of images? • Image building is automatic - why don’t we just build an image for each environment?
  • 22. Why not just build lots of images? • Unit of deploy is a machine image • Images are created via an imperative set of commands - Shell Script - Ansible • What is in each image? What is different?
  • 23. Immutable-ish • Scripts at startup handle differences • Consul cluster? - consul-template
  • 25. Fudgetown • Many dozens of microservices • All with configuration files - XML, yaml, ini, other
  • 26. Fudgetown • Multiple processes make up a single ‘service’ • All have to be started in a specific order
  • 27. Fudgetown • Deploying changes takes much longer - ~10-15 minutes for a Packer build and deployment to test infra • Tests on minor changes take a lot longer
  • 28. Fudgetown • We don’t know what the state of our instances is, or should be • We don’t know whether config files were written successfully • It takes ages to test things
  • 29. Back to the drawing board • Doing the thing the ‘cool kids’ say they are doing is not the path to technical success • Our customers care whether their app is working, not how
  • 30. What do we actually need? • Infrastructure and configuration in a known and verifiable state • Self-healing • Fault tolerant - should continue to work even if a whole data centre (‘AZ’) fails
  • 31. • Autoscaling which works every time • New instances which provision quickly (autoscaling) • Automated deployments - Possibly Canary, Blue/Green • Nice to have: quick to test changes What do we actually need?
  • 32. Instance configuration in a known state • We need a way to describe configuration on the machine • A declarative language • Should tell us if something went wrong
  • 33.
  • 34. Except.. • Puppet master doesn’t lend itself to an autoscaling world - Performance bottleneck bringing up new instances - Single point of failure - Especially in the zone failure scenario
  • 35. The rules • Terminating an instance should always automatically give you a replacement which works - Even if external repos are down • CentOS mirrors • EPEL • Elasticsearch yum repo • Gem • Pip • We should expect data centre (‘AZ’) failure
  • 36. How do we do it? • Packer - base common AMI • Puppet • S3 • yum/apt • Jenkins
  • 38. Packer • Build a base image • Generally common to all roles • Sometimes will have per-role AMIs • pip/gem dependencies generally installed here - Easier than building a package, even with FPM • Install big RPMs here to save time at provisioning
  • 39. Masterless Puppet • Put the Puppet manifests and modules on an instance • Run puppet apply
  • 40. Distributing Puppet • Puppet needs to be on every instance • Build an RPM/DEB containing Puppet manifests/modules • Add to a RPM/DEB repo in S3 • Script at startup (cloud-init) installs Puppet • Puppet runs from systemd❤
  • 41. External Repos • Mirror CentOS, etc repos in S3 • Repos are copied as part of deployment process - Dev repos continually updated - When code is promoted to next step (eg staging), repos also copied - OS upgrades are a part of the normal deployment process
  • 42. Repos in S3 • Puppet, application code in yum repos in S3 • Repo created from a Terraform module • Just drop your RPM in, it handles metadata generation https://registry.terraform.io/ modules/claranet/s3-yum- repo/aws
  • 43. Config updates • AWS provides SSM • SSM triggers updating Puppet RPM, running Puppet • ~120 seconds from commit to Puppet run finishing
  • 44. Success • We have been using this approach for 6+ years • Tried other approaches • Always came back for apps unsuitable for containerisation
  • 45. Your problems are not my problems • Have lovely 12 factor apps? • Why are you wasting time building infrastructure?!
  • 46.
  • 47. Career advice • You don’t get paid to build infrastructure • ‘Serverless’ isn’t NoOps • Understanding distributed systems and their many failure modes the path to future success
  • 48. Conclusions • Concentrate on the desired outcome, not what somebody at a conference said worked for them • Find the things that will give you the most success most easily, then iterate
  • 49. • Architect for ease of management • Don’t be constrained by ‘best practice’ • Don’t be embarrassed by ‘ugly hacks’ when they solve real problems Conclusions