SlideShare a Scribd company logo
DW3
Adopting DevOps
6/7/2017 1:30:00 PM
DW3 Implement DevOps Like a
Unicorn-Even If You're Not One
Presented by:
Mason Leung
Grand Rounds
Brought to you by:
350 Corporate Way, Suite 400, Orange Park, FL 32073
888-­‐268-­‐8770 ·∙ 904-­‐278-­‐0524 - info@techwell.com - https://www.techwell.com/
Mason Leung
Grand Rounds
A backend developer with an interest in infrastructure and operations, Mason
Leung is an infrastructure engineer at Grand Rounds, a health tech company that
enables patients better access to care providers. In his career roles, Mason has
experience defining and establishing a DevOps foundation and culture. Mason is
passionate about enhancing developer efficiency and experience through
automation, better tooling, and education. On weekends he mentors high school
students who are interested in math and STEM. Mason's lifetime goal is to start a
tutoring center and provide free lessons to disadvantaged students in San
Francisco. Reach Mason at terajukun@gmail.com.
1
Implement DevOps Like A Unicorn Even
You Don't Work At One
2 | © 2017 Grand Rounds, Inc.
Background
• Mason Leung
• Infrastructure Engineer
3 | © 2017 Grand Rounds, Inc.
"What do you do?"
Asked by my 7 years old niece
4 | © 2017 Grand Rounds, Inc.
Implement DevOps Like A
Unicorn Even You Don't
Work At One
5 | © 2017 Grand Rounds, Inc.
What is an unicorn?
• Wikipedia: Company valued over $1B
• 2013 Aileen Lee, VC
6 | © 2017 Grand Rounds, Inc.
No Unicorn
7 | © 2017 Grand Rounds, Inc.
Forrest vs Tree
vs
8 | © 2017 Grand Rounds, Inc.
Scenario Question
9 | © 2017 Grand Rounds, Inc.
What would you do?
10 | © 2017 Grand Rounds, Inc.
Plan of Attack
The goal as an infrastructure engineer is to
identify components of the platform whether
it is a process or resources that are
potential bottlenecks, figure a way to break
them.
11 | © 2017 Grand Rounds, Inc.
Implicit Goal
Bus Factor N to N+1
Hopefully N != 1
12 | © 2017 Grand Rounds, Inc.
Let's Begin
Components to increase
scalability and agility
(from the infrastructure perspective)
13 | © 2017 Grand Rounds, Inc.
Deployment
14 | © 2017 Grand Rounds, Inc.
Deployment
Loosely defined term
15 | © 2017 Grand Rounds, Inc.
Deployment
• Resource Provision
• Configuration Management
• Code Deploy
16 | © 2017 Grand Rounds, Inc.
Resource Provision
• How do I set up the platform?
• Is it in the Cloud?
17 | © 2017 Grand Rounds, Inc.
Lots of Questions
• What are the needed resources?
• What are the security groups and access
control?
• What are the VPN access on premise and
remote?
• What to do with persistent data?
18 | © 2017 Grand Rounds, Inc.
19 | © 2017 Grand Rounds, Inc.
Codify your infrastructure
20 | © 2017 Grand Rounds, Inc.
21 | © 2017 Grand Rounds, Inc.
Is there a DR in the house?
22 | © 2017 Grand Rounds, Inc.
Terraform: First Try
• One huge file
• Good for proof of concept
• Good learning experience
• Problems: organization and collaboration
23 | © 2017 Grand Rounds, Inc.
Terraform: Second Try
• Break down
components
• Separation of
environments
• Problem: organization
and collaboration
24 | © 2017 Grand Rounds, Inc.
Terraform: Third Try
• Use Terragrunt for state locking
• DRY with module
25 | © 2017 Grand Rounds, Inc.
Considerations
• Terraform by applications vs one repo for
all applications
• Module organization
• functional vs flat
26 | © 2017 Grand Rounds, Inc.
The Benefits
• Infrastructure reproducibility
• Documentation
27 | © 2017 Grand Rounds, Inc.
What separates a good
programmer and an
excellent programmer?
28 | © 2017 Grand Rounds, Inc.
Excellent programmer
documents
29 | © 2017 Grand Rounds, Inc.
Codify Your Infrastructure
• Flexibility and reproducibility
• Documentation
• Traceability of changes
• A step toward DR
30 | © 2017 Grand Rounds, Inc.
Configuration Management
31 | © 2017 Grand Rounds, Inc.
In The Past
• apt-get install manually
• shell scripts
32 | © 2017 Grand Rounds, Inc.
Which one?
33 | © 2017 Grand Rounds, Inc.
A Third Option?
34 | © 2017 Grand Rounds, Inc.
Benefits
• Environmental
Attributes
35 | © 2017 Grand Rounds, Inc.
Benefits
• Integration with
other tools
36 | © 2017 Grand Rounds, Inc.
Benefits
• Shorten debug
loop
37 | © 2017 Grand Rounds, Inc.
Benefits
• Community cookbooks or manifests
• Lock down version and portability
38 | © 2017 Grand Rounds, Inc.
Benefit
• Documentation
39 | © 2017 Grand Rounds, Inc.
Continuous Delivery
No longer a luxury, but a necessity
40 | © 2017 Grand Rounds, Inc.
Concepts
• Continuous Integration
• constantly merging
• Continuous Delivery
• constantly deploying
41 | © 2017 Grand Rounds, Inc.
The Old Deploy Pipeline
42 | © 2017 Grand Rounds, Inc.
The Old Pipeline
• Mason Leung
• Infrastructure Engineering @
GrandRounds
43 | © 2017 Grand Rounds, Inc.
Short Term Fix
Automate commit
messages to slack
with gem
44 | © 2017 Grand Rounds, Inc.
Short Term Fix
Score =( Number of
commits ) x (Hours
since deploy)
45 | © 2017 Grand Rounds, Inc.
46 | © 2017 Grand Rounds, Inc.
Considerations on CD
• Buy in from managers and developers
• Homogenous deploy tool
• In house vs hosted solution or both
47 | © 2017 Grand Rounds, Inc.
Considerations on CD
• Monitoring core metrics
• Run Jenkins backup
• Modular services
• Application and infrastructure cadence
48 | © 2017 Grand Rounds, Inc.
A Very Important Lesson
49 | © 2017 Grand Rounds, Inc.
Do NOT build
customized tools unless
you absolutely have to
50 | © 2017 Grand Rounds, Inc.
Case 1
• EC2 Creator
• Bring up EC2 in console
• Use knife-ec2 instead
• Run chef configuration
51 | © 2017 Grand Rounds, Inc.
Problems
• Works great for EC2 only
• Our platform has other resources
• A bigger picture
52 | © 2017 Grand Rounds, Inc.
Are we in the business
of writing ops tools?
53 | © 2017 Grand Rounds, Inc.
Lessons
• Think about your value proposition
• Google for tools
• Ask questions on mailing list or /r/devops
• Documentation
54 | © 2017 Grand Rounds, Inc.
Case 2
• Home grown CI system
• build under 15 minutes
• parallelization with containers
• split up test with profiler
55 | © 2017 Grand Rounds, Inc.
Building a CI System
From Scratch is Fun
56 | © 2017 Grand Rounds, Inc.
Maintaining a CI System is
Not Fun
57 | © 2017 Grand Rounds, Inc.
The Trouble Continue
• Build start to run more than 15 minutes
• Increases parallelism
• Cost of CI vs production
58 | © 2017 Grand Rounds, Inc.
The Real Issues
• Poorly written nested tests
• New code makes requests to DB
• Not enough tests ran
59 | © 2017 Grand Rounds, Inc.
Lessons Learned
• Keep good relationship
• Understand the problem beneath
• Pay down technical debt
• Look at non-functional features
60 | © 2017 Grand Rounds, Inc.
Building Customized Solutions
• Always ask
• What is the real problem?
• Are there existing solutions?
• Enough support within the org?
61 | © 2017 Grand Rounds, Inc.
Your Great
Customized
Solution Is A
Snowflake
62 | © 2017 Grand Rounds, Inc.
If You Insist...
63 | © 2017 Grand Rounds, Inc.
So Far
• Resource provisioning
• Configuration management
• Code deployment
• Use existing tools
• Resists making snowflakes
• Documentation
64 | © 2017 Grand Rounds, Inc.
Putting All
Your Eggs In
One Basket
65 | © 2017 Grand Rounds, Inc.
Multiple Vendors
• DNS: DNSMadeEasy
• CDN: EdgeCast
• Other resources: AWS
66 | © 2017 Grand Rounds, Inc.
A Big Migration
• VPC migration
• DNS and CDN consolidation
• Finish before the holiday season starts
67 | © 2017 Grand Rounds, Inc.
Three Phrases
• DNS Migration
• CDN Migration
• VPC Migration
68 | © 2017 Grand Rounds, Inc.
DNS Migration
• Create new host zone in R53
• Update domain registrar
• Export zone file in DNSME and reimport
on R53
• Monitor queries
69 | © 2017 Grand Rounds, Inc.
Redirect Problem
• Nifty redirect feature
• blog.example.com to example.com/blog
• vpn.example.com to http://1.2.3.4
70 | © 2017 Grand Rounds, Inc.
Redirect Problem Solution
• Do it through S3
• Run your own redirect service
• Third party
71 | © 2017 Grand Rounds, Inc.
Third Party Redirect
Not a lot of choices
for URL redirect
72 | © 2017 Grand Rounds, Inc.
Lesson Learned
• Ask questions
• Look at nifty features
• Be transparent
• Migration goes according to plan
73 | © 2017 Grand Rounds, Inc.
CDN Migration
• Weighted policy in Route 53
• Two type of contents
• S3
• Assets on EC2 behind ELB
74 | © 2017 Grand Rounds, Inc.
Migration Steps
• Enable CloudFront for either a S3 bucket
or an ELB
• Forward the HOST header to enable SSL
in CloudFront
• Split CDN reference into two in Route 53
• Dial up traffic slowly
• Repeat
75 | © 2017 Grand Rounds, Inc.
A Redirect Loop
• A catch all /platform/ regex left in route
• DDos-ing ourselves
platform.example.com
sfa.example.com
sfp.example.com
76 | © 2017 Grand Rounds, Inc.
Overload our ELB
• ELB not warm enough
• Call Amazon ahead of time to warm up
77 | © 2017 Grand Rounds, Inc.
Lessons Learned
• Understand your usage pattern, watch for
capacity issue
• Always have another pair of eyes
• Monitor core metrics
78 | © 2017 Grand Rounds, Inc.
VPC Migration
• Beginning of October
• Smoother than expected
79 | © 2017 Grand Rounds, Inc.
Clean Up and Review
• Review our architecture
• Design with 10x growth
• Using internal ELBs
• Rewrite pingdom checks
• Copy RDS backups with Lambda
80 | © 2017 Grand Rounds, Inc.
Implement DevOps Like A
Unicorn Even You Don't
Work At One
81 | © 2017 Grand Rounds, Inc.
Principles
• Transparency
• Repeatability
• Codify your infrastructure
• Use configuration management tools
• Documentation
• Agility
• Have a CD pipeline
• Monitoring
• Identify core metrics
• Resist snowflakes
• Don't reinvent the wheel
82 | © 2017 Grand Rounds, Inc.
FIN

More Related Content

What's hot (20)

PDF
DataOps, DevOps and the Developer: Treating Database Code Just Like App Code
DevOps.com
 
PPTX
Oracle Open World 2017 Delphix and DBVisit
Kellyn Pot'Vin-Gorman
 
PDF
DOES14: Scott Prugh, CSG - DevOps and Lean in Legacy Environments
DevOps Enterprise Summmit
 
PPTX
DevOpsGroup Cloud Adoption Frameworks - agile south coast
DevOpsGroup
 
PPTX
Cloudy with a Chance of Databases
Kellyn Pot'Vin-Gorman
 
PDF
What is continuous improvement
LibbySchulze
 
PPTX
DevOpsGuys Scaling DevOps @ #CIOWaterCooler - June 2018
DevOpsGroup
 
PDF
Who's Who in Container Land
Mike Kavis
 
PDF
Cloud Native Operations
Michael Mueller
 
PDF
DevOps and Decoys How to Build a Successful Microsoft DevOps Including the Data
Kellyn Pot'Vin-Gorman
 
PDF
DevOps Vancouver Meetup - WSBC Progress
Andre Kaminski
 
PPTX
Accelerate your dev ops transformation with continuous automation
Mike Kavis
 
PPTX
Why Cloud and DevOps are interlinked?
Newt Global Consulting LLC
 
PDF
My code, my environment, and yes, my data
Sanjeev Sharma
 
PPTX
SQL Saturday San Diego
Kellyn Pot'Vin-Gorman
 
PDF
DevOps Operations Challenges
Vijaya K
 
PDF
Collaborate PeopleSoft keynote session: Cloudy Skies Today and Tomorrow
Smart ERP Solutions, Inc.
 
PPTX
How We Do DevOps at Walmart: OneOps OSS Application Lifecycle Management Plat...
WalmartLabs
 
PDF
How to Start Your Application Modernization Journey
VMware Tanzu
 
PPTX
WinOps - Lessons learned from Enterprise DevOps with Microsoft technologies ...
DevOpsGroup
 
DataOps, DevOps and the Developer: Treating Database Code Just Like App Code
DevOps.com
 
Oracle Open World 2017 Delphix and DBVisit
Kellyn Pot'Vin-Gorman
 
DOES14: Scott Prugh, CSG - DevOps and Lean in Legacy Environments
DevOps Enterprise Summmit
 
DevOpsGroup Cloud Adoption Frameworks - agile south coast
DevOpsGroup
 
Cloudy with a Chance of Databases
Kellyn Pot'Vin-Gorman
 
What is continuous improvement
LibbySchulze
 
DevOpsGuys Scaling DevOps @ #CIOWaterCooler - June 2018
DevOpsGroup
 
Who's Who in Container Land
Mike Kavis
 
Cloud Native Operations
Michael Mueller
 
DevOps and Decoys How to Build a Successful Microsoft DevOps Including the Data
Kellyn Pot'Vin-Gorman
 
DevOps Vancouver Meetup - WSBC Progress
Andre Kaminski
 
Accelerate your dev ops transformation with continuous automation
Mike Kavis
 
Why Cloud and DevOps are interlinked?
Newt Global Consulting LLC
 
My code, my environment, and yes, my data
Sanjeev Sharma
 
SQL Saturday San Diego
Kellyn Pot'Vin-Gorman
 
DevOps Operations Challenges
Vijaya K
 
Collaborate PeopleSoft keynote session: Cloudy Skies Today and Tomorrow
Smart ERP Solutions, Inc.
 
How We Do DevOps at Walmart: OneOps OSS Application Lifecycle Management Plat...
WalmartLabs
 
How to Start Your Application Modernization Journey
VMware Tanzu
 
WinOps - Lessons learned from Enterprise DevOps with Microsoft technologies ...
DevOpsGroup
 

Similar to Implement DevOps Like a Unicorn—Even If You’re Not One (20)

PDF
DevOps Pragmatic Overview
Mykola Marzhan
 
PDF
Introduction to DevOps
OCTO Technology
 
PDF
Cloud adoption fails - 5 ways deployments go wrong and 5 solutions
Yevgeniy Brikman
 
PPTX
Resilience and Security @ Scale: Lessons Learned
Jason Chan
 
PDF
Herding cats in the Cloud
Dewey Sasser
 
PPTX
RightScale User Conference: Why RightScale?
Erik Osterman
 
PDF
Hybird Cloud - An adoption roadmap
John Georgiadis
 
PDF
Forging a New Path to Equitable Justice – Platform Engineering for State Gove...
Chris Wahl
 
PDF
Forging a New Path to Equitable Justice – Platform Engineering for State Gove...
Chris Wahl
 
PDF
Distributed software services to the cloud without breaking a sweat
José Ferreiro
 
PDF
Deploying distributed software services to the cloud without breaking a sweat
Susan Potter
 
PDF
Infrastructure as Code
Robert Greiner
 
PPTX
Cloud Application Security: Lessons Learned
Jason Chan
 
PDF
97 Things Every Cloud Engineer Should Know.pdf
منیزہ ہاشمی
 
PDF
Teaching Elephants to Dance (and Fly!) A Developer's Journey to Digital Trans...
Burr Sutter
 
PPTX
CuriousMinds and Siemens in Brasov 2015 - Building and Developing for the Clo...
Vadim Zendejas
 
PDF
Cloud Native Application Development
Siva Rama Krishna Chunduru
 
PDF
DevOps, Common use cases, Architectures, Best Practices
Shiva Narayanaswamy
 
PDF
Leveraging Automation for a Disposable Infrastructure
Mike Fowler
 
PDF
Itsummit2015 blizzard
kevin_donovan
 
DevOps Pragmatic Overview
Mykola Marzhan
 
Introduction to DevOps
OCTO Technology
 
Cloud adoption fails - 5 ways deployments go wrong and 5 solutions
Yevgeniy Brikman
 
Resilience and Security @ Scale: Lessons Learned
Jason Chan
 
Herding cats in the Cloud
Dewey Sasser
 
RightScale User Conference: Why RightScale?
Erik Osterman
 
Hybird Cloud - An adoption roadmap
John Georgiadis
 
Forging a New Path to Equitable Justice – Platform Engineering for State Gove...
Chris Wahl
 
Forging a New Path to Equitable Justice – Platform Engineering for State Gove...
Chris Wahl
 
Distributed software services to the cloud without breaking a sweat
José Ferreiro
 
Deploying distributed software services to the cloud without breaking a sweat
Susan Potter
 
Infrastructure as Code
Robert Greiner
 
Cloud Application Security: Lessons Learned
Jason Chan
 
97 Things Every Cloud Engineer Should Know.pdf
منیزہ ہاشمی
 
Teaching Elephants to Dance (and Fly!) A Developer's Journey to Digital Trans...
Burr Sutter
 
CuriousMinds and Siemens in Brasov 2015 - Building and Developing for the Clo...
Vadim Zendejas
 
Cloud Native Application Development
Siva Rama Krishna Chunduru
 
DevOps, Common use cases, Architectures, Best Practices
Shiva Narayanaswamy
 
Leveraging Automation for a Disposable Infrastructure
Mike Fowler
 
Itsummit2015 blizzard
kevin_donovan
 
Ad

More from TechWell (20)

PDF
Failing and Recovering
TechWell
 
PDF
Instill a DevOps Testing Culture in Your Team and Organization
TechWell
 
PDF
Test Design for Fully Automated Build Architecture
TechWell
 
PDF
System-Level Test Automation: Ensuring a Good Start
TechWell
 
PDF
Build Your Mobile App Quality and Test Strategy
TechWell
 
PDF
Testing Transformation: The Art and Science for Success
TechWell
 
PDF
Implement BDD with Cucumber and SpecFlow
TechWell
 
PDF
Develop WebDriver Automated Tests—and Keep Your Sanity
TechWell
 
PDF
Ma 15
TechWell
 
PDF
Eliminate Cloud Waste with a Holistic DevOps Strategy
TechWell
 
PDF
Transform Test Organizations for the New World of DevOps
TechWell
 
PDF
The Fourth Constraint in Project Delivery—Leadership
TechWell
 
PDF
Resolve the Contradiction of Specialists within Agile Teams
TechWell
 
PDF
Pin the Tail on the Metric: A Field-Tested Agile Game
TechWell
 
PDF
Agile Performance Holarchy (APH)—A Model for Scaling Agile Teams
TechWell
 
PDF
A Business-First Approach to DevOps Implementation
TechWell
 
PDF
Databases in a Continuous Integration/Delivery Process
TechWell
 
PDF
Mobile Testing: What—and What Not—to Automate
TechWell
 
PDF
Cultural Intelligence: A Key Skill for Success
TechWell
 
PDF
Turn the Lights On: A Power Utility Company's Agile Transformation
TechWell
 
Failing and Recovering
TechWell
 
Instill a DevOps Testing Culture in Your Team and Organization
TechWell
 
Test Design for Fully Automated Build Architecture
TechWell
 
System-Level Test Automation: Ensuring a Good Start
TechWell
 
Build Your Mobile App Quality and Test Strategy
TechWell
 
Testing Transformation: The Art and Science for Success
TechWell
 
Implement BDD with Cucumber and SpecFlow
TechWell
 
Develop WebDriver Automated Tests—and Keep Your Sanity
TechWell
 
Ma 15
TechWell
 
Eliminate Cloud Waste with a Holistic DevOps Strategy
TechWell
 
Transform Test Organizations for the New World of DevOps
TechWell
 
The Fourth Constraint in Project Delivery—Leadership
TechWell
 
Resolve the Contradiction of Specialists within Agile Teams
TechWell
 
Pin the Tail on the Metric: A Field-Tested Agile Game
TechWell
 
Agile Performance Holarchy (APH)—A Model for Scaling Agile Teams
TechWell
 
A Business-First Approach to DevOps Implementation
TechWell
 
Databases in a Continuous Integration/Delivery Process
TechWell
 
Mobile Testing: What—and What Not—to Automate
TechWell
 
Cultural Intelligence: A Key Skill for Success
TechWell
 
Turn the Lights On: A Power Utility Company's Agile Transformation
TechWell
 
Ad

Recently uploaded (20)

PPTX
Migrating Millions of Users with Debezium, Apache Kafka, and an Acyclic Synch...
MD Sayem Ahmed
 
PPTX
Writing Better Code - Helping Developers make Decisions.pptx
Lorraine Steyn
 
PDF
Linux Certificate of Completion - LabEx Certificate
VICTOR MAESTRE RAMIREZ
 
PDF
Automate Cybersecurity Tasks with Python
VICTOR MAESTRE RAMIREZ
 
PDF
Build It, Buy It, or Already Got It? Make Smarter Martech Decisions
bbedford2
 
PPTX
The Role of a PHP Development Company in Modern Web Development
SEO Company for School in Delhi NCR
 
PPTX
An Introduction to ZAP by Checkmarx - Official Version
Simon Bennetts
 
PDF
Revenue streams of the Wazirx clone script.pdf
aaronjeffray
 
PPTX
Agentic Automation Journey Session 1/5: Context Grounding and Autopilot for E...
klpathrudu
 
PDF
GetOnCRM Speeds Up Agentforce 3 Deployment for Enterprise AI Wins.pdf
GetOnCRM Solutions
 
PDF
Efficient, Automated Claims Processing Software for Insurers
Insurance Tech Services
 
PDF
Thread In Android-Mastering Concurrency for Responsive Apps.pdf
Nabin Dhakal
 
PDF
vMix Pro 28.0.0.42 Download vMix Registration key Bundle
kulindacore
 
PDF
MiniTool Partition Wizard 12.8 Crack License Key LATEST
hashhshs786
 
PDF
iTop VPN With Crack Lifetime Activation Key-CODE
utfefguu
 
PDF
Mobile CMMS Solutions Empowering the Frontline Workforce
CryotosCMMSSoftware
 
PPTX
Java Native Memory Leaks: The Hidden Villain Behind JVM Performance Issues
Tier1 app
 
PPTX
A Complete Guide to Salesforce SMS Integrations Build Scalable Messaging With...
360 SMS APP
 
PDF
Powering GIS with FME and VertiGIS - Peak of Data & AI 2025
Safe Software
 
PPTX
Tally software_Introduction_Presentation
AditiBansal54083
 
Migrating Millions of Users with Debezium, Apache Kafka, and an Acyclic Synch...
MD Sayem Ahmed
 
Writing Better Code - Helping Developers make Decisions.pptx
Lorraine Steyn
 
Linux Certificate of Completion - LabEx Certificate
VICTOR MAESTRE RAMIREZ
 
Automate Cybersecurity Tasks with Python
VICTOR MAESTRE RAMIREZ
 
Build It, Buy It, or Already Got It? Make Smarter Martech Decisions
bbedford2
 
The Role of a PHP Development Company in Modern Web Development
SEO Company for School in Delhi NCR
 
An Introduction to ZAP by Checkmarx - Official Version
Simon Bennetts
 
Revenue streams of the Wazirx clone script.pdf
aaronjeffray
 
Agentic Automation Journey Session 1/5: Context Grounding and Autopilot for E...
klpathrudu
 
GetOnCRM Speeds Up Agentforce 3 Deployment for Enterprise AI Wins.pdf
GetOnCRM Solutions
 
Efficient, Automated Claims Processing Software for Insurers
Insurance Tech Services
 
Thread In Android-Mastering Concurrency for Responsive Apps.pdf
Nabin Dhakal
 
vMix Pro 28.0.0.42 Download vMix Registration key Bundle
kulindacore
 
MiniTool Partition Wizard 12.8 Crack License Key LATEST
hashhshs786
 
iTop VPN With Crack Lifetime Activation Key-CODE
utfefguu
 
Mobile CMMS Solutions Empowering the Frontline Workforce
CryotosCMMSSoftware
 
Java Native Memory Leaks: The Hidden Villain Behind JVM Performance Issues
Tier1 app
 
A Complete Guide to Salesforce SMS Integrations Build Scalable Messaging With...
360 SMS APP
 
Powering GIS with FME and VertiGIS - Peak of Data & AI 2025
Safe Software
 
Tally software_Introduction_Presentation
AditiBansal54083
 

Implement DevOps Like a Unicorn—Even If You’re Not One

  • 1. DW3 Adopting DevOps 6/7/2017 1:30:00 PM DW3 Implement DevOps Like a Unicorn-Even If You're Not One Presented by: Mason Leung Grand Rounds Brought to you by: 350 Corporate Way, Suite 400, Orange Park, FL 32073 888-­‐268-­‐8770 ·∙ 904-­‐278-­‐0524 - [email protected] - https://www.techwell.com/
  • 2. Mason Leung Grand Rounds A backend developer with an interest in infrastructure and operations, Mason Leung is an infrastructure engineer at Grand Rounds, a health tech company that enables patients better access to care providers. In his career roles, Mason has experience defining and establishing a DevOps foundation and culture. Mason is passionate about enhancing developer efficiency and experience through automation, better tooling, and education. On weekends he mentors high school students who are interested in math and STEM. Mason's lifetime goal is to start a tutoring center and provide free lessons to disadvantaged students in San Francisco. Reach Mason at [email protected].
  • 3. 1 Implement DevOps Like A Unicorn Even You Don't Work At One
  • 4. 2 | © 2017 Grand Rounds, Inc. Background • Mason Leung • Infrastructure Engineer
  • 5. 3 | © 2017 Grand Rounds, Inc. "What do you do?" Asked by my 7 years old niece
  • 6. 4 | © 2017 Grand Rounds, Inc. Implement DevOps Like A Unicorn Even You Don't Work At One
  • 7. 5 | © 2017 Grand Rounds, Inc. What is an unicorn? • Wikipedia: Company valued over $1B • 2013 Aileen Lee, VC
  • 8. 6 | © 2017 Grand Rounds, Inc. No Unicorn
  • 9. 7 | © 2017 Grand Rounds, Inc. Forrest vs Tree vs
  • 10. 8 | © 2017 Grand Rounds, Inc. Scenario Question
  • 11. 9 | © 2017 Grand Rounds, Inc. What would you do?
  • 12. 10 | © 2017 Grand Rounds, Inc. Plan of Attack The goal as an infrastructure engineer is to identify components of the platform whether it is a process or resources that are potential bottlenecks, figure a way to break them.
  • 13. 11 | © 2017 Grand Rounds, Inc. Implicit Goal Bus Factor N to N+1 Hopefully N != 1
  • 14. 12 | © 2017 Grand Rounds, Inc. Let's Begin Components to increase scalability and agility (from the infrastructure perspective)
  • 15. 13 | © 2017 Grand Rounds, Inc. Deployment
  • 16. 14 | © 2017 Grand Rounds, Inc. Deployment Loosely defined term
  • 17. 15 | © 2017 Grand Rounds, Inc. Deployment • Resource Provision • Configuration Management • Code Deploy
  • 18. 16 | © 2017 Grand Rounds, Inc. Resource Provision • How do I set up the platform? • Is it in the Cloud?
  • 19. 17 | © 2017 Grand Rounds, Inc. Lots of Questions • What are the needed resources? • What are the security groups and access control? • What are the VPN access on premise and remote? • What to do with persistent data?
  • 20. 18 | © 2017 Grand Rounds, Inc.
  • 21. 19 | © 2017 Grand Rounds, Inc. Codify your infrastructure
  • 22. 20 | © 2017 Grand Rounds, Inc.
  • 23. 21 | © 2017 Grand Rounds, Inc. Is there a DR in the house?
  • 24. 22 | © 2017 Grand Rounds, Inc. Terraform: First Try • One huge file • Good for proof of concept • Good learning experience • Problems: organization and collaboration
  • 25. 23 | © 2017 Grand Rounds, Inc. Terraform: Second Try • Break down components • Separation of environments • Problem: organization and collaboration
  • 26. 24 | © 2017 Grand Rounds, Inc. Terraform: Third Try • Use Terragrunt for state locking • DRY with module
  • 27. 25 | © 2017 Grand Rounds, Inc. Considerations • Terraform by applications vs one repo for all applications • Module organization • functional vs flat
  • 28. 26 | © 2017 Grand Rounds, Inc. The Benefits • Infrastructure reproducibility • Documentation
  • 29. 27 | © 2017 Grand Rounds, Inc. What separates a good programmer and an excellent programmer?
  • 30. 28 | © 2017 Grand Rounds, Inc. Excellent programmer documents
  • 31. 29 | © 2017 Grand Rounds, Inc. Codify Your Infrastructure • Flexibility and reproducibility • Documentation • Traceability of changes • A step toward DR
  • 32. 30 | © 2017 Grand Rounds, Inc. Configuration Management
  • 33. 31 | © 2017 Grand Rounds, Inc. In The Past • apt-get install manually • shell scripts
  • 34. 32 | © 2017 Grand Rounds, Inc. Which one?
  • 35. 33 | © 2017 Grand Rounds, Inc. A Third Option?
  • 36. 34 | © 2017 Grand Rounds, Inc. Benefits • Environmental Attributes
  • 37. 35 | © 2017 Grand Rounds, Inc. Benefits • Integration with other tools
  • 38. 36 | © 2017 Grand Rounds, Inc. Benefits • Shorten debug loop
  • 39. 37 | © 2017 Grand Rounds, Inc. Benefits • Community cookbooks or manifests • Lock down version and portability
  • 40. 38 | © 2017 Grand Rounds, Inc. Benefit • Documentation
  • 41. 39 | © 2017 Grand Rounds, Inc. Continuous Delivery No longer a luxury, but a necessity
  • 42. 40 | © 2017 Grand Rounds, Inc. Concepts • Continuous Integration • constantly merging • Continuous Delivery • constantly deploying
  • 43. 41 | © 2017 Grand Rounds, Inc. The Old Deploy Pipeline
  • 44. 42 | © 2017 Grand Rounds, Inc. The Old Pipeline • Mason Leung • Infrastructure Engineering @ GrandRounds
  • 45. 43 | © 2017 Grand Rounds, Inc. Short Term Fix Automate commit messages to slack with gem
  • 46. 44 | © 2017 Grand Rounds, Inc. Short Term Fix Score =( Number of commits ) x (Hours since deploy)
  • 47. 45 | © 2017 Grand Rounds, Inc.
  • 48. 46 | © 2017 Grand Rounds, Inc. Considerations on CD • Buy in from managers and developers • Homogenous deploy tool • In house vs hosted solution or both
  • 49. 47 | © 2017 Grand Rounds, Inc. Considerations on CD • Monitoring core metrics • Run Jenkins backup • Modular services • Application and infrastructure cadence
  • 50. 48 | © 2017 Grand Rounds, Inc. A Very Important Lesson
  • 51. 49 | © 2017 Grand Rounds, Inc. Do NOT build customized tools unless you absolutely have to
  • 52. 50 | © 2017 Grand Rounds, Inc. Case 1 • EC2 Creator • Bring up EC2 in console • Use knife-ec2 instead • Run chef configuration
  • 53. 51 | © 2017 Grand Rounds, Inc. Problems • Works great for EC2 only • Our platform has other resources • A bigger picture
  • 54. 52 | © 2017 Grand Rounds, Inc. Are we in the business of writing ops tools?
  • 55. 53 | © 2017 Grand Rounds, Inc. Lessons • Think about your value proposition • Google for tools • Ask questions on mailing list or /r/devops • Documentation
  • 56. 54 | © 2017 Grand Rounds, Inc. Case 2 • Home grown CI system • build under 15 minutes • parallelization with containers • split up test with profiler
  • 57. 55 | © 2017 Grand Rounds, Inc. Building a CI System From Scratch is Fun
  • 58. 56 | © 2017 Grand Rounds, Inc. Maintaining a CI System is Not Fun
  • 59. 57 | © 2017 Grand Rounds, Inc. The Trouble Continue • Build start to run more than 15 minutes • Increases parallelism • Cost of CI vs production
  • 60. 58 | © 2017 Grand Rounds, Inc. The Real Issues • Poorly written nested tests • New code makes requests to DB • Not enough tests ran
  • 61. 59 | © 2017 Grand Rounds, Inc. Lessons Learned • Keep good relationship • Understand the problem beneath • Pay down technical debt • Look at non-functional features
  • 62. 60 | © 2017 Grand Rounds, Inc. Building Customized Solutions • Always ask • What is the real problem? • Are there existing solutions? • Enough support within the org?
  • 63. 61 | © 2017 Grand Rounds, Inc. Your Great Customized Solution Is A Snowflake
  • 64. 62 | © 2017 Grand Rounds, Inc. If You Insist...
  • 65. 63 | © 2017 Grand Rounds, Inc. So Far • Resource provisioning • Configuration management • Code deployment • Use existing tools • Resists making snowflakes • Documentation
  • 66. 64 | © 2017 Grand Rounds, Inc. Putting All Your Eggs In One Basket
  • 67. 65 | © 2017 Grand Rounds, Inc. Multiple Vendors • DNS: DNSMadeEasy • CDN: EdgeCast • Other resources: AWS
  • 68. 66 | © 2017 Grand Rounds, Inc. A Big Migration • VPC migration • DNS and CDN consolidation • Finish before the holiday season starts
  • 69. 67 | © 2017 Grand Rounds, Inc. Three Phrases • DNS Migration • CDN Migration • VPC Migration
  • 70. 68 | © 2017 Grand Rounds, Inc. DNS Migration • Create new host zone in R53 • Update domain registrar • Export zone file in DNSME and reimport on R53 • Monitor queries
  • 71. 69 | © 2017 Grand Rounds, Inc. Redirect Problem • Nifty redirect feature • blog.example.com to example.com/blog • vpn.example.com to http://1.2.3.4
  • 72. 70 | © 2017 Grand Rounds, Inc. Redirect Problem Solution • Do it through S3 • Run your own redirect service • Third party
  • 73. 71 | © 2017 Grand Rounds, Inc. Third Party Redirect Not a lot of choices for URL redirect
  • 74. 72 | © 2017 Grand Rounds, Inc. Lesson Learned • Ask questions • Look at nifty features • Be transparent • Migration goes according to plan
  • 75. 73 | © 2017 Grand Rounds, Inc. CDN Migration • Weighted policy in Route 53 • Two type of contents • S3 • Assets on EC2 behind ELB
  • 76. 74 | © 2017 Grand Rounds, Inc. Migration Steps • Enable CloudFront for either a S3 bucket or an ELB • Forward the HOST header to enable SSL in CloudFront • Split CDN reference into two in Route 53 • Dial up traffic slowly • Repeat
  • 77. 75 | © 2017 Grand Rounds, Inc. A Redirect Loop • A catch all /platform/ regex left in route • DDos-ing ourselves platform.example.com sfa.example.com sfp.example.com
  • 78. 76 | © 2017 Grand Rounds, Inc. Overload our ELB • ELB not warm enough • Call Amazon ahead of time to warm up
  • 79. 77 | © 2017 Grand Rounds, Inc. Lessons Learned • Understand your usage pattern, watch for capacity issue • Always have another pair of eyes • Monitor core metrics
  • 80. 78 | © 2017 Grand Rounds, Inc. VPC Migration • Beginning of October • Smoother than expected
  • 81. 79 | © 2017 Grand Rounds, Inc. Clean Up and Review • Review our architecture • Design with 10x growth • Using internal ELBs • Rewrite pingdom checks • Copy RDS backups with Lambda
  • 82. 80 | © 2017 Grand Rounds, Inc. Implement DevOps Like A Unicorn Even You Don't Work At One
  • 83. 81 | © 2017 Grand Rounds, Inc. Principles • Transparency • Repeatability • Codify your infrastructure • Use configuration management tools • Documentation • Agility • Have a CD pipeline • Monitoring • Identify core metrics • Resist snowflakes • Don't reinvent the wheel
  • 84. 82 | © 2017 Grand Rounds, Inc. FIN