SlideShare a Scribd company logo
DevOps and Β AWS
Shiva Β Narayanaswamy
Solution Β Architect
~11.6s
Mean Β time between Β 
deployments Β 
(weekday)
~1,079
Max Β number Β of Β 
deployments Β in Β a Β 
single Β hour
~10,000
Mean Β number Β of Β hosts Β 
simultaneously Β 
receiving Β a Β 
deployment Β 
~30,000
Max Β number Β of Β hosts Β 
simultaneously Β 
receiving Β a Β 
deployment Β 
DEPLOYMENTS Β AT Β AMAZON.COM
75%
Reduction Β in Β 
outages Β triggered Β 
by Β software Β 
deployments Β 
since Β 2006
90%
Reduction Β in Β 
outage Β minutes Β 
triggered Β by Β 
software Β 
deployments
Business Β Value Β of Β Frequent Β Deployments
~0.001%
Software Β 
deployments Β 
cause Β an
outage
DevOps Culture
Innovation Β & Β Stability
Business
Development Operations
Build Β it Β faster Keep Β it Β stable
Continuous Β Innovation
Business Β 
Idea
Implementation
Testing
Release
Customer Β 
Feedback
Customer
Deploying Β More Β Frequently Β Lowers Β Risk
Smaller Β Effort
β€œMinimized Β Risk”
Frequent Β Release Β Events:
β€œAgile Β Methodology”
Time
Change
Rare Β Release Β Events:
β€œWaterfall Β Methodology”
Larger Β Effort
β€œIncreased Β  Risk”
Time
Change
Knowledge Β is Β power
Requirements
Gathering
Release
Development Β 
and Β Check Β In
Test Β and Β QA
Some Β Learning
Lots Β of Β Learning
Minimal Β Learning
Cycle Β Time
Change Β is Β inevitable
β€’ Change Β is Β the Β root cause Β of Β most Β outages
β€’ This Β leaves Β two Β approaches:
-Β­ Make Β it Β a Β big Β deal
-Β­ Small Β iterative Β non Β events
β€œDo painful things more
frequently, so you can
make it less painful…”
-Β­ Adrian Β Cockcroft, Β  Architect, Β  Netflix
Waterfall
Analyze Design Build Test Deploy
Agile
Sprint
Deploy
Agile-Β­er
A D B T
Sprint
A D B T D
Sprint Sprint
A D B T D A D B T D
Agile-Β­er
Dev QA Ops
Dev / Β QA Ops
Dev/QA/Ops Dev/QA/Ops Dev/QA/Ops
Sprint
A D B T
Sprint
A D B T
DevOps is a Re-Org!
-Β­ Adrian Β Cockcroft, Β  Architect, Β  Netflix
RE
– A Β philosophy? Β  Cultural Β  change? Β Paradigm Β shift Β ?
– Alignment Β  of Β development Β  and Β IT Β operations Β with Β better Β communication Β  and Β 
collaboration Β  ?
– Improvement Β in Β software Β deployment Β  ?
– Breaking Β  down Β the Β barriers Β between Β development Β  and Β IT Β operations Β ?
– Akin Β to Β Agile Β software Β development Β  applied Β to Β infrastructure Β and Β IT Β 
operations Β 
– Set Β of Β tools Β and Β processes
– It’s Β all Β of Β the Β above!
Code
W
a
l
l
Developer IT Β Operations
DevOps
Business Β Case Requirements Use Β Case Features Plan Go Β to Β market
Business
Design Code Refactor Unit Β Test Bug Β Fix Deliver
Developers
(application)
Provision Configure Orchestrate Deploy Report Monitor
IT Β Operations
Agile Β 
Development
DevOps
β€’ Continuous Β Integration
β€’ Continuous Β Deployment
β€’ IT Β Automation
β€’ Application Β Management
β€’ Iterative Β development
β€’ Scrum, Β sprints, Β stories
β€’ Velocity
Business
Agility
IT
Agility
Business Β and Β IT Β agility
Building Β Teams
β€’ Encourage a Β fail Β fast, Β learn Β quick Β mindset
β€’ Foster innovation Β and Β accountability
β€’ Promote open Β and Β honest Β sharing Β of Β lessons Β 
learned
β€’ Build Β trust Β across Β organizational Β boundaries
-Β­ Include Β all Β the Β stakeholders
β€’ Expect Β that Β it Β will Β be Β a Β work-Β­in-Β­progress
1. Customer Β Obsession
2. Β Ownership
3. Β Invent Β and Β Simplify
4. Β Are Β Right, Β A Β Lot
5. Β Hire Β and Β Develop Β the Β Best
6. Β Insist Β on Β the Β Highest Β 
Standards
7. Β Think Β Big
8. Β Bias Β for Β Action
9. Β Frugality
10. Β Learn Β and Β Be Β Curious
11. Β Earn Β Trust Β of Β Others
12. Β Dive Β Deep
13. Β Have Β Backbone;ΝΎ Β Disagree Β 
and Β Commit
14. Β Deliver Β Results
Amazon Β Leadership Β Principles
DevOps Technology
The Β DevOps Β Stack
Continuous Β Deployment
Delivery Β Pipelines
Deployment Β Automation
Continuous
Integration
Automated
Testing
Configuration
Management
Agile
Communication
β€’ Infrastructure Β as Β code
β€’ Application Β and Β Infrastructure Β version Β management
β€’ Continuous Β Integration
β€’ Test Β Automation
β€’ Continuous Β Deployment
β€’ Monitoring Β and Β logging
DevOps Β Practices
Version
Control
CI Β Server
Package Β 
Builder
Deploy Β 
ServerCommit to Β 
Git/master
Dev
Get Β / Β 
Pull
Code
AMIs
Distributed Β Builds
Run Β Tests Β in Β parallel
Staging Β Env
Test Β Env
Code
Config
Tests
Prod Β Env
Push
Config
Install
Create
Repo
CloudFormation Β 
Templates Β for Β Env
Generate
Sample Β Application Β Cycle
Version Β 
Control
CI Β Server
Package Β 
Builder
Deploy Β 
ServerCommit Β to Β 
Git/master
Dev
Get Β / Β 
Pull
Code
AMIs
Send Β Build Β Report Β to Β Dev
Stop Β everything Β if Β build Β failed
Distributed Β Builds
Run Β Tests Β in Β parallel
Staging Β Env
Test Β Env
Code
Config
Tests
Prod Β Env
Push
Config
Install
Create
Repo
CloudFormation Β 
Templates Β for Β Env
Generate
Continuous Integration
Continuous Β Integration
β€’ Every Β developer Β check-Β­in Β initiates Β a Β build
-Β­ Builds Β are Β fully Β automated
-Β­ Tests validate Β every Β check-Β­in
β€’ Instant Β feedback Β for Β developers
-Β­ The Β build Β must Β remain Β fast
β€’ Minimizes Β the Β impact Β of Β broken Β builds
-Β­ Bugs Β don’t Β accumulate
β€’ Drives Β the Β culture Β of Β small, Β frequent Β releases
Version Β 
Control
CI Β Server
Package Β 
Builder
Deploy Β 
ServerCommit Β to Β 
Git/master
Dev
Get Β / Β 
Pull
Code
AMIs
Send Β Build Β Report Β to Β Dev
Stop Β everything Β if Β build Β failed
Distributed Β Builds
Run Β Tests Β in Β parallel
Staging Β Env
Test Β Env
Code
Config
Tests
Prod Β Env
Push
Config
Install
Create
Repo
CloudFormation Β 
Templates Β for Β Env
Generate
Continuous Β Delivery/Deployment
Continuous Β Deployment Β vs Delivery
β€’ Automated, Β repeatable Β process Β to Β push Β changes
β€’ Hardens, Β de-Β­risks Β the Β deployment Β process
β€’ Immediate Β feedback from Β users
β€’ Supports Β A/B Β testing Β or Β β€œWe Β test Β customer Β 
reactions Β to Β features Β in Β production”
β€’ Gives Β us Β a Β breadth Β of Β data Β points Β across Β our Β 
applications
Continuous Β Delivery
Automated Β Testing
β€’ Robust, Β automated Β testing Β drives Β confidence Β in Β 
the Β entire Β process
β€’ Testing Β is Β not Β viewed Β as Β a Β β€œphase” Β of Β a Β project
-Β­ Testing Β starts Β on Β day Β one
β€’ View Β failures Β as Β successes
β€’ Don’t Β overlook Β testing Β the Β infrastructure
-Β­ Are Β you Β ready Β for Β the Β Simian Β Army?
β€’ Testing Β is Β everyone’s responsibility
Version Β Control
Build/
Compile
Code
Dev
Unit Β Test
App Β Code
IT Β Ops
DR Β Env
Test Β Env
Prod Β Env
Dev Env
Application
Write
App Β 
Code
Infrastructure
CloudFormation
tar, Β war, Β zip
yum, Β rpmDeploy
App
Package
Applicatio
n
Deploy Β application Β 
only
Deploy Β infrastructure Β 
only
AMI
Build
AMIs
Validate
Template
s
Write
Infra Β 
Code
Deploy
Infras
Automate
Deployme
nt
Artifact Β Repository
Continuous Β Integration Β / Β Deployment Β & Β Automation
DevOps Stack Β on Β AWS
28
MonitorProvisionDeployTestBuildCode
AWS Β Elastic Β Beanstalk
CloudWatchCloudFormationCodeDeploy
CodeCommit CodePipeline
AWS Β Opsworks
AWS Β Elastic Β Container Β Service
CodeCommit
β€’ Data Β redundancy Β across Β Availability Β Zones Β 
β€’ Data-Β­at-Β­rest Β encryption
β€’ Integrated Β with Β AWS Β Identity Β and Β Access Β Management
β€’ No Β repo Β size Β limit
git push CodeCommit
Git objects
in Β Amazon Β S3
Git index
in Β Amazon Β 
DynamoDB
Encryption Β key
in Β AWS Β KMS
SSH Β or Β HTTPS
Secure, Β scalable, Β and Β managed Β Git source Β control
Same Β Git experience
$ git clone https://git-codecommit.us-east-1.amazonaws.com/v1/repos/aws-cli
Cloning into 'aws-cli'...
Receiving objects: 100% (16032/16032), 5.55 MiB | 1.25 MiB/s, done.
Resolving deltas: 100% (9900/9900), done.
Checking connectivity... done.
$ nano README.rst
$ git commit -am 'updated README'
[master 4fa0318] updated README
1 file changed, 1 insertion(+)
$ git push
Counting objects: 3, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (3/3), done.
Writing objects: 100% (3/3), 297 bytes | 0 bytes/s, done.
Total 3 (delta 2), reused 0 (delta 0)
remote:
To https://git-codecommit.us-east-1.amazonaws.com/v1/repos/aws-cli
4dacd6d..4fa0318 master -> master
CodePipeline
β€’ Customizable Β workflow Β engine
β€’ Integrate Β with Β partner Β and Β custom Β systems
β€’ Visual Β editor Β and Β status
Continuous Β delivery Β and Β release Β automation, Β just Β like Β Amazon
Build
1) Β Build
2) Β Unit Β test
1) Deploy
2) Β UI Β test
Source Beta Production
1) Β Deploy
2) Β Load Β test
Gamma
1) Β Deploy Β region1
2) Β Deploy Β region2
3) Β Deploy Β region3
CodePipeline : Β Mockup
CodeDeploy
β€’ Scale Β from Β 1 Β instance Β to Β thousands
β€’ Deploy Β without Β downtime
β€’ Centralize Β deployment Β control Β and Β monitoring
Staging
CodeDeployv1, Β v2, Β v3
Production
Dev
Coordinate Β automated Β deployments, Β just Β like Β Amazon
Application
revisions
Deployment Β groups
Step Β 1: Β Package Β your Β application Β (with Β an Β AppSpec
file)
version: 0.0
os: linux
files:
- source: chef/
destination: /etc/chef/codedeploy
- source: target/hello.war
destination: /var/lib/tomcat6/webapps
hooks:
ApplicationStop:
- location: deploy_hooks/stop-tomcat.sh
BeforeInstall:
- location: deploy_hooks/install-chef.sh
AfterInstall:
- location: deploy_hooks/librarian-install.sh
ApplicationStart:
- location: deploy_hooks/chef-solo.sh
ValidateService:
- location: deploy_hooks/verify_service.sh
Step Β 1: Β Package Β your Β application Β (with Β an Β AppSpec
file)
version: 0.0
os: linux
files:
- source: chef/
destination: /etc/chef/codedeploy
- source: target/hello.war
destination: /var/lib/tomcat6/webapps
hooks:
ApplicationStop:
- location: deploy_hooks/stop-tomcat.sh
BeforeInstall:
- location: deploy_hooks/install-chef.sh
AfterInstall:
- location: deploy_hooks/librarian-install.sh
ApplicationStart:
- location: deploy_hooks/chef-solo.sh
ValidateService:
- location: deploy_hooks/verify_service.sh
Step Β 1: Β Package Β your Β application Β (with Β an Β AppSpec
file)
version: 0.0
os: linux
files:
- source: chef/
destination: /etc/chef/codedeploy
- source: target/hello.war
destination: /var/lib/tomcat6/webapps
hooks:
ApplicationStop:
- location: deploy_hooks/stop-tomcat.sh
BeforeInstall:
- location: deploy_hooks/install-chef.sh
AfterInstall:
- location: deploy_hooks/librarian-install.sh
ApplicationStart:
- location: deploy_hooks/chef-solo.sh
ValidateService:
- location: deploy_hooks/verify_service.sh
Step Β 2: Β Set Β up Β your Β target Β environments
Agent Agent Agent
Staging
Agent Agent
Agent Agent
Agent
Agent
Production
Deployment Β groupDeployment Β group
Group Β instances Β by:
β€’ Auto Β Scaling Β group
β€’ Amazon Β EC2 Β tag
β€’ On-Β­premises Β tag
Step Β 3: Β Deploy!
aws deploy create-deployment 
--application-name MyApp 
--deployment-group-name TargetGroup 
--s3-location bucket=MyBucket,key=MyApp.zip
AWS Β CLI Β & Β SDKs
AWS Β Console
CI Β / Β CD Β Partners
GitHub
Deployment Β config – Choose Β speed
v2 v1 v1 v1 v1 v1 v1 v1
v2 v2 v2 v2 v1 v1 v1 v1
v2 v2 v2 v2 v2 v2 v2 v2
One-Β­at-Β­a-Β­time
Half-Β­at-Β­a-Β­time
All-Β­at-Β­once
Rolling Β update  – Deploy Β without Β downtime
v1v1 v1
Load Β Balancer
Rolling Β update  – Deploy Β without Β downtime
v1v2 v1
Load Β Balancer
Rolling Β update  – Deploy Β without Β downtime
v2v2 v1
Load Β Balancer
Rolling Β update  – Deploy Β without Β downtime
v2v2v2
Load Β Balancer
Rolling Β update  – Deploy Β without Β downtime
v2v2 v2
Load Β Balancer
Health Β Tracking  – Catch Β deployment Β problems
v2v2 v2
Load Β Balancer
Health Β tracking  – Catch Β deployment Β problems
v3 v2 v2Stop
Load Β Balancer
Health Β tracking  – Catch Β deployment Β problems
v2v2 v2
Load Β Balancer
Rollback
Health Β tracking  – Catch Β deployment Β problems
v2v2 v2
Load Β Balancer
DevOps Stack Β on Β AWS
49
MonitorProvisionDeployTestBuildCode
AWS Β Elastic Β Beanstalk
CloudWatchCloudFormationCodeDeploy
CodeCommit CodePipeline
AWS Β Opsworks
AWS Β Elastic Β Container Β Service
Automate Β with Β AWS Β CLI
Automate Β with Β AWS Β SDK
Β§ο‚§ Infrastructure Β as Β Code
Β§ο‚§ Integrates Β with Β version Β control
Β§ο‚§ JSON Β format
Β§ο‚§ Templates
Β§ο‚§ Stacks
Β§ο‚§ Supports Β most Β AWS Β resource Β typesAWS CloudFormation
AWS Β Cloudformation
{
"Description" Β  : Β "Create Β  an Β EC2 Β instance Β running Β the Β Amazon Β Linux Β 32 Β bit Β AMI.”,
"Parameters" Β  : Β { Β 
"KeyPair" Β  : Β { Β 
"Description" Β  : Β "The Β EC2 Β Key Β Pair Β  to Β allow Β SSH Β  access Β to Β the Β instance", Β 
"Type" Β : Β "String" Β 
} Β 
},
"Resources" Β  : Β { Β 
"Ec2Instance" Β  : Β { Β 
"Type" Β : Β "AWS::EC2::Instance", Β 
"Properties" Β  : Β { Β 
"KeyName" Β  : Β { Β "Ref" Β : Β "KeyPair" Β  }, Β 
"ImageId" Β  : Β "ami-Β­75g0061f”,
β€œInstanceType” Β : Β β€œm1.medium” Β 
} Β 
} Β 
}, Β 
"Outputs" Β : Β { Β 
"InstanceId" Β  : Β { Β 
"Description" Β  : Β "The Β InstanceId Β of Β the Β newly Β created Β  EC2 Β instance", Β 
"Value" Β  : Β { Β "Ref" Β : Β "Ec2Instance” Β  } Β 
} Β 
}
}
AWS Β Cloudformation
Template Β File Β 
Defining Β Stack
Git
Subversion
Mercurial
Dev
Test
Prod
The entire application can be
represented in an AWS
CloudFormation template.
Use the version
control system of
your choice to store
and track changes to
this template
Build out multiple
environments, such
as for Development,
Test, and Production
using the template
AWS Β Cloudformation
Describing Β Infrastructure Β with Β Code
Developers
&
Operations
Internal Β 
Git
CI Β Server
Pre-Β­commit Β 
Hook
Testing Β Environment Β Subnet
CI Β Workers
Dev Β Environment Β VPC Β Subnet
DEV Β WEB Β 
ELBDev Β Stack
Tier Β 1
Dev Β Stack
Tier Β 2
Dev Β MySQL Β 
DB Β Instance
DEV Β APP Β 
ELB
VPN Β 
TUNNEL
VPN Β facing Β VPC Β  Subnet
Internet Β 
Gateway
VPN Β 
Endpoint
Dev Β Admin Β 
Instance
NAT Β Instance
Amazon Β S3
Amazon
DynamoDB
Amazon Β SQS
Amazon Β 
CloudFront
Amazon Β 
Route Β 53
This Β entire Β infrastructure Β stack Β can Β be Β constructed, Β configured, Β and Β deployed Β with Β code:
Infrastructure Β Code
The Β code Β that Β describes Β infrastructure Β should Β inherit Β 
the Β same Β values Β applied Β to Β application Β code
– Not JUST revision Β control
– Make Β use Β of Β bug Β tracking/ticketing Β systems
– Peer Β reviews Β of Β changes Β before Β they Β happen
– Establish Β infrastructure Β code Β patterns/designs
– Test Β infrastructure Β changes Β like Β code Β changes
β€’ AWS Β OpsWorks makes Β it Β easy Β to Β deploy Β 
& Β operate Β apps Β of Β all Β shapes Β and Β sizes
β€’ Define Β configurations Β  for Β your Β 
entire Β environment Β in Β a Β format Β that Β 
you Β can Β maintain Β  and Β version Β 
just Β like Β your Β application Β  source Β code
β€’ Uses Β the Β Chef Β framework Β so Β you Β can Β 
bring Β your Β own Β recipes Β or Β leverage Β 
100’s Β of Β community-Β­built Β  configurations
AWS Β Opsworks
β€’ Quickly Β deploy Β and Β manage Β applications Β 
in Β the Β AWS Β cloud Β without Β worrying Β about Β 
the Β application Β  infrastructure Β 
β€’ Automatically Β  handles Β all
the Β details Β of Β resource Β provisioning,
load Β balancing Β  & Β auto-Β­scaling
β€’ Launch Β your Β Java, Β PHP, Β .NET, Β Node.js, Β 
Python, Β Ruby Β and Β Docker applications Β 
in Β a Β matter Β of Β minutes
AWS Β Beanstalk
WWW Β 
server
WWW Β 
server
WWW Β 
server
WWW Β 
server
Logging Β 
Service
Pay
Service
Process
Service
Process
Service
Process
Service
Process
Service
Cluster Β of Β underlying
EC2 Β instances
WWW Β containers Application-Β­specific Β microservices
WWW Β 
server
WWW Β 
server
Scale Β out Β 
at Β the Β 
container Β 
level
Launching Β 
containers Β is Β in Β 
the Β order Β of Β 
seconds  – very Β 
fast Β to Β react
AWS Β Elastic Β Container Β Service
AWS Β Tools
β€’ CloudFormation
β€’ Elastic Β Beanstalk
β€’ OpsWorks
3rd-Β­Party Β Tools
β€’ Chef
β€’ Puppet
What Β are Β we Β deploying? Β How Β much Β control Β do Β we Β want?
β€’ Deploy Β in Β place Β 
– Deploy Β all Β at Β once Β (Service Β outage)
– Rolling Β updates
β€’ Blue-Β­Green Β Deployment
– Discrete Β environment
β€’ Multiple Β environments Β from Β branches
β€’ Support Β A/B Β testing
β€’ β€œRolling Β DNS”
β€’ Alternate Β Blue-Β­Green Β (Red-Β­Black?) Β deployment
β€’ Alternate Β auto Β scaling Β group
β€’ Avoid Β messing Β with Β DNS
Deployment Β Approaches
CodeDeploy
ALMA Service Icons
Simple Deploy System
Simple Deploy System
Simple Deploy System
Pipelines
Pipelines
Deploy Β in Β place  – Rolling Β update
ELB
S3
EC2
ALMA Service Icons
Simple Deploy System
Simple Deploy System
Simple Deploy System
Pipelines
Pipelines
Deploy Β in Β place  – Rolling Β update
ALMA Service Icons
Simple Deploy System
Simple Deploy System
Simple Deploy System
Pipelines
Pipelines
Deploy Β in Β place  – Rolling Β update
ALMA Service Icons
Simple Deploy System
Simple Deploy System
Simple Deploy System
Pipelines
Pipelines
Deploy Β in Β place  – Rolling Β update
ALMA Service Icons
Simple Deploy System
Simple Deploy System
Simple Deploy System
Pipelines
Pipelines
Deploy Β in Β place  – Rolling Β update
ALMA Service Icons
Simple Deploy System
Simple Deploy System
Simple Deploy System
Pipelines
Pipelines
Pipelines
Deploy Β in Β place  – Rolling Β update
Amazon Β 
Route Β 53
EC2 Β 
Instances
ELB
100%
DynamoDB
MySQL Β RDS
Instance
ElastiCache
Cache Β Node
Blue-Β­Green Β Deployment
Amazon Β 
Route Β 53
EC2 Β 
Instances
EL
B
EC2 Β 
Instances
EL
B
100%
UAT
DynamoDB
MySQL Β RDS
Instance
ElastiCache
Cache Β Node
Blue-Β­Green Β Deployment
Amazon Β 
Route Β 53
EC2 Β 
Instances
EL
B
EC2 Β 
Instances
EL
B
90% 10%
DynamoDB MySQL Β 
RDS
Instance
ElastiCach
e Cache Β 
Node
Blue-Β­Green Β Deployment
Amazon Β 
Route Β 53
EC2 Β 
Instances
ELB
EC2 Β 
Instances
ELB
50% 50%
DynamoDB MySQL Β 
RDS
Instance
ElastiCache
Cache Β 
Node
Blue-Β­Green Β Deployment
Amazon Β 
Route Β 53
EC2 Β 
Instances
ELB
EC2 Β 
Instances
ELB
0% 100%
DynamoDB MySQL Β 
RDS
Instance
ElastiCache
Cache Β Node
Blue-Β­Green Β Deployment
Amazon Β 
Route Β 53
EC2 Β 
Instances
EL
B
EC2 Β 
Instances
ELB
0% 100%
DynamoDB MySQL Β 
RDS
Instance
ElastiCache
Cache Β 
Node
Blue-Β­Green Β Deployment
Auto Β 
Scaling Β 
Group
V1
ELB
Amazon Β 
Relational Β 
Database Β 
Service Β (RDS)
Red-Β­Black Β Deployment
Auto Β 
Scaling Β 
Group
V1
Auto Β Scaling Β 
Group
V2
ELB
Amazon Β 
Relational Β 
Database Β 
Service Β (RDS)
UAT
Red-Β­Black Β Deployment
Auto Β 
Scaling Β 
Group
V1
Auto Β Scaling Β 
Group
V2
ELB
Amazon Β 
Relational Β 
Database Β 
Service Β (RDS)
ALM | Β Red-Β­Black Β Deployment
Auto Β Scaling Β 
Group
V2
ELB
Amazon Β 
Relational Β 
Database Β 
Service Β (RDS)
Red-Β­Black Β Deployment
Monitoring Β & Β Metrics Β : Β The Β DevOps Β Pulse
β€’ Track Β every Β resource Β possible
β€’ Alert Β on Β services, availability, Β and response Β times
β€’ Capture, Β learn, Β and Β improve
β€’ Share Β access Β with Β everyone Β on Β the Β team
β€’ Plan metrics Β and Β monitoring Β into Β the Β lifecycle
DevOps and AWS
DevOps and AWS
Where Β do Β I Β go Β from Β here?
β€’ Collect Β Metrics. Β Graph Β anything Β that Β moves
β€’ Log Β everything, Β Centralize Β logging, Β Log Β 
Analytics
β€’ Infrastructure Β as Β Code
β€’ Automated Β configuration Β management
β€’ One Β click Β environment Β creation
β€’ CI-Β­CD Β pipelines
β€’ Automated Β testing
DevOps and AWS

More Related Content

PPTX
Snowflake Automated Deployments / CI/CD Pipelines
PPTX
Introduction to DevOps on AWS
DOCX
Hospital management system project
PPTX
DevOps Tutorial For Beginners | DevOps Tutorial | DevOps Tools | DevOps Train...
PDF
Software Engineering - chp8- deployment
PPTX
IP addressing and Subnetting PPT
PDF
Getting started with Ansible
PPTX
DevOps introduction
Snowflake Automated Deployments / CI/CD Pipelines
Introduction to DevOps on AWS
Hospital management system project
DevOps Tutorial For Beginners | DevOps Tutorial | DevOps Tools | DevOps Train...
Software Engineering - chp8- deployment
IP addressing and Subnetting PPT
Getting started with Ansible
DevOps introduction

What's hot (20)

PDF
What is DevOps | DevOps Introduction | DevOps Training | DevOps Tutorial | Ed...
PPTX
Introduction to DevOps
PPTX
DevOps Introduction
PPTX
An introduction to DevOps
PPTX
Introduction To DevOps | Devops Tutorial For Beginners | DevOps Training For ...
PPTX
DevOps Foundation
PDF
DevOps
PPTX
DevOps 101 - an Introduction to DevOps
PDF
DevOps Powerpoint Presentation Slides
PDF
Introduction to DevOps
PPTX
What is DevOps? | DevOps Introduction | DevOps Tools | DevOps Tutorial For Be...
PDF
How to implement DevOps in your Organization
PDF
DevOps introduction
PPTX
How To Become A DevOps Engineer | Who Is A DevOps Engineer? | DevOps Engineer...
PPTX
DevOps introduction
PPTX
Devops ppt
PPTX
DevOps
PPTX
Kubernetes Introduction
PPTX
DevOps - Overview - One of the Top Trends in IT Industry
PDF
DevOps - A Gentle Introduction
What is DevOps | DevOps Introduction | DevOps Training | DevOps Tutorial | Ed...
Introduction to DevOps
DevOps Introduction
An introduction to DevOps
Introduction To DevOps | Devops Tutorial For Beginners | DevOps Training For ...
DevOps Foundation
DevOps
DevOps 101 - an Introduction to DevOps
DevOps Powerpoint Presentation Slides
Introduction to DevOps
What is DevOps? | DevOps Introduction | DevOps Tools | DevOps Tutorial For Be...
How to implement DevOps in your Organization
DevOps introduction
How To Become A DevOps Engineer | Who Is A DevOps Engineer? | DevOps Engineer...
DevOps introduction
Devops ppt
DevOps
Kubernetes Introduction
DevOps - Overview - One of the Top Trends in IT Industry
DevOps - A Gentle Introduction
Ad

Viewers also liked (20)

PPTX
Harmonizing Multi-tenant HBase Clusters for Managing Workload Diversity
PPT
Experimental Photography Artist Research
PDF
Lifehacking met Evernote
PDF
High Availability Architecture for Legacy Stuff - a 10.000 feet overview
PPTX
Big Data Commercialization and associated IoT Platform Implications by Ramnik...
PDF
Cwin16 tls-s2-0945-going cloud native
PPTX
How OpenTable uses Big Data to impact growth by Raman Marya
DOCX
Elk Reporting Ii
PDF
μ†Œμ…œ μ½”λ”© GitHub & branch & branch strategy
PDF
Plan de transport 2014: le Brabant Flamand
Β 
ODT
Nato Constitution- & Laws. Chris Helweg
PDF
Bennett raglinphotography
PDF
Channel partners: Get ready for future trends in client solutions
PPTX
SQL saturday 623 TLV - SQL AZURE
PPTX
Azure OMS
PPTX
SPSNL17 - Securing Office 365 and Microsoft Azure like a rock star (or groupi...
Β 
PDF
AI = SE , giip system manage automation with A.I
PDF
Emerging Technologies: Heroku for ISVs (October 13, 2014)
PDF
The Loss of HMAS SYDNEY 2: Medical Aspects- Westphalen
PPT
15 oefeningen schakelen van weerstanden
Harmonizing Multi-tenant HBase Clusters for Managing Workload Diversity
Experimental Photography Artist Research
Lifehacking met Evernote
High Availability Architecture for Legacy Stuff - a 10.000 feet overview
Big Data Commercialization and associated IoT Platform Implications by Ramnik...
Cwin16 tls-s2-0945-going cloud native
How OpenTable uses Big Data to impact growth by Raman Marya
Elk Reporting Ii
μ†Œμ…œ μ½”λ”© GitHub & branch & branch strategy
Plan de transport 2014: le Brabant Flamand
Β 
Nato Constitution- & Laws. Chris Helweg
Bennett raglinphotography
Channel partners: Get ready for future trends in client solutions
SQL saturday 623 TLV - SQL AZURE
Azure OMS
SPSNL17 - Securing Office 365 and Microsoft Azure like a rock star (or groupi...
Β 
AI = SE , giip system manage automation with A.I
Emerging Technologies: Heroku for ISVs (October 13, 2014)
The Loss of HMAS SYDNEY 2: Medical Aspects- Westphalen
15 oefeningen schakelen van weerstanden
Ad

Similar to DevOps and AWS (20)

PDF
DevOps, Common use cases, Architectures, Best Practices
PPTX
Fllow con 2014
PDF
The Continuous delivery Value @ codemotion 2014
PDF
The Continuous delivery value - Funaro
PDF
[India Merge World Tour] Electric Cloud
PPTX
DevSecOps - It can change your life (cycle)
PPTX
How to go from waterfall app dev to secure agile development in 2 weeks
PDF
Panel Discussion Continuous Deployment in SaaS
PDF
Pivotal korea transformation_strategy_seminar_enterprise_dev_ops_20160630_v1.0
PPT
Continuous Deployment
PPTX
Introduction to continuous delivery
PDF
DTS-1778 Understanding DevOps - IBM InterConnect Session
PPTX
Agile & DevOps - It's all about project success
PPTX
Leading the Transformation
PDF
Deployment Automation for Hybrid Cloud and Multi-Platform Environments
PPTX
Dev ops != Dev+Ops
PDF
Lessons Learned Replatforming A Large Machine Learning Application To Apache ...
PPTX
Continuous Delivery: why ? where to start ? how to scale ?
PDF
Getting to Walk with DevOps
PDF
Dev ops for mainframe innovate session 2402
DevOps, Common use cases, Architectures, Best Practices
Fllow con 2014
The Continuous delivery Value @ codemotion 2014
The Continuous delivery value - Funaro
[India Merge World Tour] Electric Cloud
DevSecOps - It can change your life (cycle)
How to go from waterfall app dev to secure agile development in 2 weeks
Panel Discussion Continuous Deployment in SaaS
Pivotal korea transformation_strategy_seminar_enterprise_dev_ops_20160630_v1.0
Continuous Deployment
Introduction to continuous delivery
DTS-1778 Understanding DevOps - IBM InterConnect Session
Agile & DevOps - It's all about project success
Leading the Transformation
Deployment Automation for Hybrid Cloud and Multi-Platform Environments
Dev ops != Dev+Ops
Lessons Learned Replatforming A Large Machine Learning Application To Apache ...
Continuous Delivery: why ? where to start ? how to scale ?
Getting to Walk with DevOps
Dev ops for mainframe innovate session 2402

More from Shiva Narayanaswamy (20)

PDF
State of Union - Containerz
PDF
Pets, Cattle, Rabbits and Microbes
PDF
Leveraging Elastic Web Scale Computing with AWS
PDF
Platform for Innovation - AWS
PDF
Application Delivery Patterns
PPTX
AWS Security and SecOps
PDF
ECS and ECR deep dive
PDF
AWS Tagging Strategy
PDF
AWS + Puppet = Dynamic Scale
PDF
Build high performing mobile apps, faster with AWS
PDF
Your APIs can be soft and fluffy
PDF
Innovation at Scale - Top 10 AWS questions when you start
PDF
Event driven infrastructure
PDF
AWS Connectivity, VPC Design and Security Pro Tips
PPTX
Dev/Test Environment Provisioning and Management on AWS
PPTX
Application Lifecycle Management and Event Driven Programming on AWS
PPTX
Leveraging elastic web scale computing with AWS
PPTX
Running Hybrid Cloud Patterns on AWS
PPTX
AWS EC2 and ELB troubleshooting
PPTX
Continuous delivery and deployment on AWS
State of Union - Containerz
Pets, Cattle, Rabbits and Microbes
Leveraging Elastic Web Scale Computing with AWS
Platform for Innovation - AWS
Application Delivery Patterns
AWS Security and SecOps
ECS and ECR deep dive
AWS Tagging Strategy
AWS + Puppet = Dynamic Scale
Build high performing mobile apps, faster with AWS
Your APIs can be soft and fluffy
Innovation at Scale - Top 10 AWS questions when you start
Event driven infrastructure
AWS Connectivity, VPC Design and Security Pro Tips
Dev/Test Environment Provisioning and Management on AWS
Application Lifecycle Management and Event Driven Programming on AWS
Leveraging elastic web scale computing with AWS
Running Hybrid Cloud Patterns on AWS
AWS EC2 and ELB troubleshooting
Continuous delivery and deployment on AWS

Recently uploaded (20)

PPTX
artificial intelligence overview of it and more
PPTX
newyork.pptxirantrafgshenepalchinachinane
PPTX
Introduction to cybersecurity and digital nettiquette
PDF
The Ikigai Template _ Recalibrate How You Spend Your Time.pdf
PPT
Ethics in Information System - Management Information System
PDF
Introduction to the IoT system, how the IoT system works
PDF
Best Practices for Testing and Debugging Shopify Third-Party API Integrations...
PDF
Smart Home Technology for Health Monitoring (www.kiu.ac.ug)
PPTX
Database Information System - Management Information System
PPTX
Module 1 - Cyber Law and Ethics 101.pptx
PDF
Exploring VPS Hosting Trends for SMBs in 2025
PDF
mera desh ae watn.(a source of motivation and patriotism to the youth of the ...
PPT
Design_with_Watersergyerge45hrbgre4top (1).ppt
PPTX
June-4-Sermon-Powerpoint.pptx USE THIS FOR YOUR MOTIVATION
DOCX
Unit-3 cyber security network security of internet system
PPTX
t_and_OpenAI_Combined_two_pressentations
PPT
FIRE PREVENTION AND CONTROL PLAN- LUS.FM.MQ.OM.UTM.PLN.00014.ppt
PPTX
E -tech empowerment technologies PowerPoint
PDF
πŸ’° π”πŠπ“πˆ πŠπ„πŒπ„ππ€ππ†π€π πŠπˆππ„π‘πŸ’πƒ π‡π€π‘πˆ 𝐈𝐍𝐈 πŸπŸŽπŸπŸ“ πŸ’°
Β 
PPTX
Funds Management Learning Material for Beg
artificial intelligence overview of it and more
newyork.pptxirantrafgshenepalchinachinane
Introduction to cybersecurity and digital nettiquette
The Ikigai Template _ Recalibrate How You Spend Your Time.pdf
Ethics in Information System - Management Information System
Introduction to the IoT system, how the IoT system works
Best Practices for Testing and Debugging Shopify Third-Party API Integrations...
Smart Home Technology for Health Monitoring (www.kiu.ac.ug)
Database Information System - Management Information System
Module 1 - Cyber Law and Ethics 101.pptx
Exploring VPS Hosting Trends for SMBs in 2025
mera desh ae watn.(a source of motivation and patriotism to the youth of the ...
Design_with_Watersergyerge45hrbgre4top (1).ppt
June-4-Sermon-Powerpoint.pptx USE THIS FOR YOUR MOTIVATION
Unit-3 cyber security network security of internet system
t_and_OpenAI_Combined_two_pressentations
FIRE PREVENTION AND CONTROL PLAN- LUS.FM.MQ.OM.UTM.PLN.00014.ppt
E -tech empowerment technologies PowerPoint
πŸ’° π”πŠπ“πˆ πŠπ„πŒπ„ππ€ππ†π€π πŠπˆππ„π‘πŸ’πƒ π‡π€π‘πˆ 𝐈𝐍𝐈 πŸπŸŽπŸπŸ“ πŸ’°
Β 
Funds Management Learning Material for Beg

DevOps and AWS

  • 1. DevOps and Β AWS Shiva Β Narayanaswamy Solution Β Architect
  • 2. ~11.6s Mean Β time between Β  deployments Β  (weekday) ~1,079 Max Β number Β of Β  deployments Β in Β a Β  single Β hour ~10,000 Mean Β number Β of Β hosts Β  simultaneously Β  receiving Β a Β  deployment Β  ~30,000 Max Β number Β of Β hosts Β  simultaneously Β  receiving Β a Β  deployment Β  DEPLOYMENTS Β AT Β AMAZON.COM
  • 3. 75% Reduction Β in Β  outages Β triggered Β  by Β software Β  deployments Β  since Β 2006 90% Reduction Β in Β  outage Β minutes Β  triggered Β by Β  software Β  deployments Business Β Value Β of Β Frequent Β Deployments ~0.001% Software Β  deployments Β  cause Β an outage
  • 5. Innovation Β & Β Stability Business Development Operations Build Β it Β faster Keep Β it Β stable
  • 7. Deploying Β More Β Frequently Β Lowers Β Risk Smaller Β Effort β€œMinimized Β Risk” Frequent Β Release Β Events: β€œAgile Β Methodology” Time Change Rare Β Release Β Events: β€œWaterfall Β Methodology” Larger Β Effort β€œIncreased Β  Risk” Time Change
  • 8. Knowledge Β is Β power Requirements Gathering Release Development Β  and Β Check Β In Test Β and Β QA Some Β Learning Lots Β of Β Learning Minimal Β Learning Cycle Β Time
  • 9. Change Β is Β inevitable β€’ Change Β is Β the Β root cause Β of Β most Β outages β€’ This Β leaves Β two Β approaches: -Β­ Make Β it Β a Β big Β deal -Β­ Small Β iterative Β non Β events
  • 10. β€œDo painful things more frequently, so you can make it less painful…” -Β­ Adrian Β Cockcroft, Β  Architect, Β  Netflix
  • 11. Waterfall Analyze Design Build Test Deploy Agile Sprint Deploy Agile-Β­er A D B T Sprint A D B T D Sprint Sprint A D B T D A D B T D Agile-Β­er Dev QA Ops Dev / Β QA Ops Dev/QA/Ops Dev/QA/Ops Dev/QA/Ops Sprint A D B T Sprint A D B T
  • 12. DevOps is a Re-Org! -Β­ Adrian Β Cockcroft, Β  Architect, Β  Netflix RE
  • 13. – A Β philosophy? Β  Cultural Β  change? Β Paradigm Β shift Β ? – Alignment Β  of Β development Β  and Β IT Β operations Β with Β better Β communication Β  and Β  collaboration Β  ? – Improvement Β in Β software Β deployment Β  ? – Breaking Β  down Β the Β barriers Β between Β development Β  and Β IT Β operations Β ? – Akin Β to Β Agile Β software Β development Β  applied Β to Β infrastructure Β and Β IT Β  operations Β  – Set Β of Β tools Β and Β processes – It’s Β all Β of Β the Β above! Code W a l l Developer IT Β Operations DevOps
  • 14. Business Β Case Requirements Use Β Case Features Plan Go Β to Β market Business Design Code Refactor Unit Β Test Bug Β Fix Deliver Developers (application) Provision Configure Orchestrate Deploy Report Monitor IT Β Operations Agile Β  Development DevOps β€’ Continuous Β Integration β€’ Continuous Β Deployment β€’ IT Β Automation β€’ Application Β Management β€’ Iterative Β development β€’ Scrum, Β sprints, Β stories β€’ Velocity Business Agility IT Agility Business Β and Β IT Β agility
  • 15. Building Β Teams β€’ Encourage a Β fail Β fast, Β learn Β quick Β mindset β€’ Foster innovation Β and Β accountability β€’ Promote open Β and Β honest Β sharing Β of Β lessons Β  learned β€’ Build Β trust Β across Β organizational Β boundaries -Β­ Include Β all Β the Β stakeholders β€’ Expect Β that Β it Β will Β be Β a Β work-Β­in-Β­progress
  • 16. 1. Customer Β Obsession 2. Β Ownership 3. Β Invent Β and Β Simplify 4. Β Are Β Right, Β A Β Lot 5. Β Hire Β and Β Develop Β the Β Best 6. Β Insist Β on Β the Β Highest Β  Standards 7. Β Think Β Big 8. Β Bias Β for Β Action 9. Β Frugality 10. Β Learn Β and Β Be Β Curious 11. Β Earn Β Trust Β of Β Others 12. Β Dive Β Deep 13. Β Have Β Backbone;ΝΎ Β Disagree Β  and Β Commit 14. Β Deliver Β Results Amazon Β Leadership Β Principles
  • 18. The Β DevOps Β Stack Continuous Β Deployment Delivery Β Pipelines Deployment Β Automation Continuous Integration Automated Testing Configuration Management Agile Communication
  • 19. β€’ Infrastructure Β as Β code β€’ Application Β and Β Infrastructure Β version Β management β€’ Continuous Β Integration β€’ Test Β Automation β€’ Continuous Β Deployment β€’ Monitoring Β and Β logging DevOps Β Practices
  • 20. Version Control CI Β Server Package Β  Builder Deploy Β  ServerCommit to Β  Git/master Dev Get Β / Β  Pull Code AMIs Distributed Β Builds Run Β Tests Β in Β parallel Staging Β Env Test Β Env Code Config Tests Prod Β Env Push Config Install Create Repo CloudFormation Β  Templates Β for Β Env Generate Sample Β Application Β Cycle
  • 21. Version Β  Control CI Β Server Package Β  Builder Deploy Β  ServerCommit Β to Β  Git/master Dev Get Β / Β  Pull Code AMIs Send Β Build Β Report Β to Β Dev Stop Β everything Β if Β build Β failed Distributed Β Builds Run Β Tests Β in Β parallel Staging Β Env Test Β Env Code Config Tests Prod Β Env Push Config Install Create Repo CloudFormation Β  Templates Β for Β Env Generate Continuous Integration
  • 22. Continuous Β Integration β€’ Every Β developer Β check-Β­in Β initiates Β a Β build -Β­ Builds Β are Β fully Β automated -Β­ Tests validate Β every Β check-Β­in β€’ Instant Β feedback Β for Β developers -Β­ The Β build Β must Β remain Β fast β€’ Minimizes Β the Β impact Β of Β broken Β builds -Β­ Bugs Β don’t Β accumulate β€’ Drives Β the Β culture Β of Β small, Β frequent Β releases
  • 23. Version Β  Control CI Β Server Package Β  Builder Deploy Β  ServerCommit Β to Β  Git/master Dev Get Β / Β  Pull Code AMIs Send Β Build Β Report Β to Β Dev Stop Β everything Β if Β build Β failed Distributed Β Builds Run Β Tests Β in Β parallel Staging Β Env Test Β Env Code Config Tests Prod Β Env Push Config Install Create Repo CloudFormation Β  Templates Β for Β Env Generate Continuous Β Delivery/Deployment
  • 25. β€’ Automated, Β repeatable Β process Β to Β push Β changes β€’ Hardens, Β de-Β­risks Β the Β deployment Β process β€’ Immediate Β feedback from Β users β€’ Supports Β A/B Β testing Β or Β β€œWe Β test Β customer Β  reactions Β to Β features Β in Β production” β€’ Gives Β us Β a Β breadth Β of Β data Β points Β across Β our Β  applications Continuous Β Delivery
  • 26. Automated Β Testing β€’ Robust, Β automated Β testing Β drives Β confidence Β in Β  the Β entire Β process β€’ Testing Β is Β not Β viewed Β as Β a Β β€œphase” Β of Β a Β project -Β­ Testing Β starts Β on Β day Β one β€’ View Β failures Β as Β successes β€’ Don’t Β overlook Β testing Β the Β infrastructure -Β­ Are Β you Β ready Β for Β the Β Simian Β Army? β€’ Testing Β is Β everyone’s responsibility
  • 27. Version Β Control Build/ Compile Code Dev Unit Β Test App Β Code IT Β Ops DR Β Env Test Β Env Prod Β Env Dev Env Application Write App Β  Code Infrastructure CloudFormation tar, Β war, Β zip yum, Β rpmDeploy App Package Applicatio n Deploy Β application Β  only Deploy Β infrastructure Β  only AMI Build AMIs Validate Template s Write Infra Β  Code Deploy Infras Automate Deployme nt Artifact Β Repository Continuous Β Integration Β / Β Deployment Β & Β Automation
  • 28. DevOps Stack Β on Β AWS 28 MonitorProvisionDeployTestBuildCode AWS Β Elastic Β Beanstalk CloudWatchCloudFormationCodeDeploy CodeCommit CodePipeline AWS Β Opsworks AWS Β Elastic Β Container Β Service
  • 29. CodeCommit β€’ Data Β redundancy Β across Β Availability Β Zones Β  β€’ Data-Β­at-Β­rest Β encryption β€’ Integrated Β with Β AWS Β Identity Β and Β Access Β Management β€’ No Β repo Β size Β limit git push CodeCommit Git objects in Β Amazon Β S3 Git index in Β Amazon Β  DynamoDB Encryption Β key in Β AWS Β KMS SSH Β or Β HTTPS Secure, Β scalable, Β and Β managed Β Git source Β control
  • 30. Same Β Git experience $ git clone https://git-codecommit.us-east-1.amazonaws.com/v1/repos/aws-cli Cloning into 'aws-cli'... Receiving objects: 100% (16032/16032), 5.55 MiB | 1.25 MiB/s, done. Resolving deltas: 100% (9900/9900), done. Checking connectivity... done. $ nano README.rst $ git commit -am 'updated README' [master 4fa0318] updated README 1 file changed, 1 insertion(+) $ git push Counting objects: 3, done. Delta compression using up to 4 threads. Compressing objects: 100% (3/3), done. Writing objects: 100% (3/3), 297 bytes | 0 bytes/s, done. Total 3 (delta 2), reused 0 (delta 0) remote: To https://git-codecommit.us-east-1.amazonaws.com/v1/repos/aws-cli 4dacd6d..4fa0318 master -> master
  • 31. CodePipeline β€’ Customizable Β workflow Β engine β€’ Integrate Β with Β partner Β and Β custom Β systems β€’ Visual Β editor Β and Β status Continuous Β delivery Β and Β release Β automation, Β just Β like Β Amazon Build 1) Β Build 2) Β Unit Β test 1) Deploy 2) Β UI Β test Source Beta Production 1) Β Deploy 2) Β Load Β test Gamma 1) Β Deploy Β region1 2) Β Deploy Β region2 3) Β Deploy Β region3
  • 33. CodeDeploy β€’ Scale Β from Β 1 Β instance Β to Β thousands β€’ Deploy Β without Β downtime β€’ Centralize Β deployment Β control Β and Β monitoring Staging CodeDeployv1, Β v2, Β v3 Production Dev Coordinate Β automated Β deployments, Β just Β like Β Amazon Application revisions Deployment Β groups
  • 34. Step Β 1: Β Package Β your Β application Β (with Β an Β AppSpec file) version: 0.0 os: linux files: - source: chef/ destination: /etc/chef/codedeploy - source: target/hello.war destination: /var/lib/tomcat6/webapps hooks: ApplicationStop: - location: deploy_hooks/stop-tomcat.sh BeforeInstall: - location: deploy_hooks/install-chef.sh AfterInstall: - location: deploy_hooks/librarian-install.sh ApplicationStart: - location: deploy_hooks/chef-solo.sh ValidateService: - location: deploy_hooks/verify_service.sh
  • 35. Step Β 1: Β Package Β your Β application Β (with Β an Β AppSpec file) version: 0.0 os: linux files: - source: chef/ destination: /etc/chef/codedeploy - source: target/hello.war destination: /var/lib/tomcat6/webapps hooks: ApplicationStop: - location: deploy_hooks/stop-tomcat.sh BeforeInstall: - location: deploy_hooks/install-chef.sh AfterInstall: - location: deploy_hooks/librarian-install.sh ApplicationStart: - location: deploy_hooks/chef-solo.sh ValidateService: - location: deploy_hooks/verify_service.sh
  • 36. Step Β 1: Β Package Β your Β application Β (with Β an Β AppSpec file) version: 0.0 os: linux files: - source: chef/ destination: /etc/chef/codedeploy - source: target/hello.war destination: /var/lib/tomcat6/webapps hooks: ApplicationStop: - location: deploy_hooks/stop-tomcat.sh BeforeInstall: - location: deploy_hooks/install-chef.sh AfterInstall: - location: deploy_hooks/librarian-install.sh ApplicationStart: - location: deploy_hooks/chef-solo.sh ValidateService: - location: deploy_hooks/verify_service.sh
  • 37. Step Β 2: Β Set Β up Β your Β target Β environments Agent Agent Agent Staging Agent Agent Agent Agent Agent Agent Production Deployment Β groupDeployment Β group Group Β instances Β by: β€’ Auto Β Scaling Β group β€’ Amazon Β EC2 Β tag β€’ On-Β­premises Β tag
  • 38. Step Β 3: Β Deploy! aws deploy create-deployment --application-name MyApp --deployment-group-name TargetGroup --s3-location bucket=MyBucket,key=MyApp.zip AWS Β CLI Β & Β SDKs AWS Β Console CI Β / Β CD Β Partners GitHub
  • 39. Deployment Β config – Choose Β speed v2 v1 v1 v1 v1 v1 v1 v1 v2 v2 v2 v2 v1 v1 v1 v1 v2 v2 v2 v2 v2 v2 v2 v2 One-Β­at-Β­a-Β­time Half-Β­at-Β­a-Β­time All-Β­at-Β­once
  • 40. Rolling Β update  – Deploy Β without Β downtime v1v1 v1 Load Β Balancer
  • 41. Rolling Β update  – Deploy Β without Β downtime v1v2 v1 Load Β Balancer
  • 42. Rolling Β update  – Deploy Β without Β downtime v2v2 v1 Load Β Balancer
  • 43. Rolling Β update  – Deploy Β without Β downtime v2v2v2 Load Β Balancer
  • 44. Rolling Β update  – Deploy Β without Β downtime v2v2 v2 Load Β Balancer
  • 45. Health Β Tracking  – Catch Β deployment Β problems v2v2 v2 Load Β Balancer
  • 46. Health Β tracking  – Catch Β deployment Β problems v3 v2 v2Stop Load Β Balancer
  • 47. Health Β tracking  – Catch Β deployment Β problems v2v2 v2 Load Β Balancer Rollback
  • 48. Health Β tracking  – Catch Β deployment Β problems v2v2 v2 Load Β Balancer
  • 49. DevOps Stack Β on Β AWS 49 MonitorProvisionDeployTestBuildCode AWS Β Elastic Β Beanstalk CloudWatchCloudFormationCodeDeploy CodeCommit CodePipeline AWS Β Opsworks AWS Β Elastic Β Container Β Service
  • 52. Β§ο‚§ Infrastructure Β as Β Code Β§ο‚§ Integrates Β with Β version Β control Β§ο‚§ JSON Β format Β§ο‚§ Templates Β§ο‚§ Stacks Β§ο‚§ Supports Β most Β AWS Β resource Β typesAWS CloudFormation AWS Β Cloudformation
  • 53. { "Description" Β  : Β "Create Β  an Β EC2 Β instance Β running Β the Β Amazon Β Linux Β 32 Β bit Β AMI.”, "Parameters" Β  : Β { Β  "KeyPair" Β  : Β { Β  "Description" Β  : Β "The Β EC2 Β Key Β Pair Β  to Β allow Β SSH Β  access Β to Β the Β instance", Β  "Type" Β : Β "String" Β  } Β  }, "Resources" Β  : Β { Β  "Ec2Instance" Β  : Β { Β  "Type" Β : Β "AWS::EC2::Instance", Β  "Properties" Β  : Β { Β  "KeyName" Β  : Β { Β "Ref" Β : Β "KeyPair" Β  }, Β  "ImageId" Β  : Β "ami-Β­75g0061f”, β€œInstanceType” Β : Β β€œm1.medium” Β  } Β  } Β  }, Β  "Outputs" Β : Β { Β  "InstanceId" Β  : Β { Β  "Description" Β  : Β "The Β InstanceId Β of Β the Β newly Β created Β  EC2 Β instance", Β  "Value" Β  : Β { Β "Ref" Β : Β "Ec2Instance” Β  } Β  } Β  } } AWS Β Cloudformation
  • 54. Template Β File Β  Defining Β Stack Git Subversion Mercurial Dev Test Prod The entire application can be represented in an AWS CloudFormation template. Use the version control system of your choice to store and track changes to this template Build out multiple environments, such as for Development, Test, and Production using the template AWS Β Cloudformation
  • 55. Describing Β Infrastructure Β with Β Code Developers & Operations Internal Β  Git CI Β Server Pre-Β­commit Β  Hook Testing Β Environment Β Subnet CI Β Workers Dev Β Environment Β VPC Β Subnet DEV Β WEB Β  ELBDev Β Stack Tier Β 1 Dev Β Stack Tier Β 2 Dev Β MySQL Β  DB Β Instance DEV Β APP Β  ELB VPN Β  TUNNEL VPN Β facing Β VPC Β  Subnet Internet Β  Gateway VPN Β  Endpoint Dev Β Admin Β  Instance NAT Β Instance Amazon Β S3 Amazon DynamoDB Amazon Β SQS Amazon Β  CloudFront Amazon Β  Route Β 53 This Β entire Β infrastructure Β stack Β can Β be Β constructed, Β configured, Β and Β deployed Β with Β code:
  • 56. Infrastructure Β Code The Β code Β that Β describes Β infrastructure Β should Β inherit Β  the Β same Β values Β applied Β to Β application Β code – Not JUST revision Β control – Make Β use Β of Β bug Β tracking/ticketing Β systems – Peer Β reviews Β of Β changes Β before Β they Β happen – Establish Β infrastructure Β code Β patterns/designs – Test Β infrastructure Β changes Β like Β code Β changes
  • 57. β€’ AWS Β OpsWorks makes Β it Β easy Β to Β deploy Β  & Β operate Β apps Β of Β all Β shapes Β and Β sizes β€’ Define Β configurations Β  for Β your Β  entire Β environment Β in Β a Β format Β that Β  you Β can Β maintain Β  and Β version Β  just Β like Β your Β application Β  source Β code β€’ Uses Β the Β Chef Β framework Β so Β you Β can Β  bring Β your Β own Β recipes Β or Β leverage Β  100’s Β of Β community-Β­built Β  configurations AWS Β Opsworks
  • 58. β€’ Quickly Β deploy Β and Β manage Β applications Β  in Β the Β AWS Β cloud Β without Β worrying Β about Β  the Β application Β  infrastructure Β  β€’ Automatically Β  handles Β all the Β details Β of Β resource Β provisioning, load Β balancing Β  & Β auto-Β­scaling β€’ Launch Β your Β Java, Β PHP, Β .NET, Β Node.js, Β  Python, Β Ruby Β and Β Docker applications Β  in Β a Β matter Β of Β minutes AWS Β Beanstalk
  • 59. WWW Β  server WWW Β  server WWW Β  server WWW Β  server Logging Β  Service Pay Service Process Service Process Service Process Service Process Service Cluster Β of Β underlying EC2 Β instances WWW Β containers Application-Β­specific Β microservices WWW Β  server WWW Β  server Scale Β out Β  at Β the Β  container Β  level Launching Β  containers Β is Β in Β  the Β order Β of Β  seconds  – very Β  fast Β to Β react AWS Β Elastic Β Container Β Service
  • 60. AWS Β Tools β€’ CloudFormation β€’ Elastic Β Beanstalk β€’ OpsWorks 3rd-Β­Party Β Tools β€’ Chef β€’ Puppet What Β are Β we Β deploying? Β How Β much Β control Β do Β we Β want?
  • 61. β€’ Deploy Β in Β place Β  – Deploy Β all Β at Β once Β (Service Β outage) – Rolling Β updates β€’ Blue-Β­Green Β Deployment – Discrete Β environment β€’ Multiple Β environments Β from Β branches β€’ Support Β A/B Β testing β€’ β€œRolling Β DNS” β€’ Alternate Β Blue-Β­Green Β (Red-Β­Black?) Β deployment β€’ Alternate Β auto Β scaling Β group β€’ Avoid Β messing Β with Β DNS Deployment Β Approaches
  • 62. CodeDeploy ALMA Service Icons Simple Deploy System Simple Deploy System Simple Deploy System Pipelines Pipelines Deploy Β in Β place  – Rolling Β update ELB S3 EC2
  • 63. ALMA Service Icons Simple Deploy System Simple Deploy System Simple Deploy System Pipelines Pipelines Deploy Β in Β place  – Rolling Β update
  • 64. ALMA Service Icons Simple Deploy System Simple Deploy System Simple Deploy System Pipelines Pipelines Deploy Β in Β place  – Rolling Β update
  • 65. ALMA Service Icons Simple Deploy System Simple Deploy System Simple Deploy System Pipelines Pipelines Deploy Β in Β place  – Rolling Β update
  • 66. ALMA Service Icons Simple Deploy System Simple Deploy System Simple Deploy System Pipelines Pipelines Deploy Β in Β place  – Rolling Β update
  • 67. ALMA Service Icons Simple Deploy System Simple Deploy System Simple Deploy System Pipelines Pipelines Pipelines Deploy Β in Β place  – Rolling Β update
  • 68. Amazon Β  Route Β 53 EC2 Β  Instances ELB 100% DynamoDB MySQL Β RDS Instance ElastiCache Cache Β Node Blue-Β­Green Β Deployment
  • 69. Amazon Β  Route Β 53 EC2 Β  Instances EL B EC2 Β  Instances EL B 100% UAT DynamoDB MySQL Β RDS Instance ElastiCache Cache Β Node Blue-Β­Green Β Deployment
  • 70. Amazon Β  Route Β 53 EC2 Β  Instances EL B EC2 Β  Instances EL B 90% 10% DynamoDB MySQL Β  RDS Instance ElastiCach e Cache Β  Node Blue-Β­Green Β Deployment
  • 71. Amazon Β  Route Β 53 EC2 Β  Instances ELB EC2 Β  Instances ELB 50% 50% DynamoDB MySQL Β  RDS Instance ElastiCache Cache Β  Node Blue-Β­Green Β Deployment
  • 72. Amazon Β  Route Β 53 EC2 Β  Instances ELB EC2 Β  Instances ELB 0% 100% DynamoDB MySQL Β  RDS Instance ElastiCache Cache Β Node Blue-Β­Green Β Deployment
  • 73. Amazon Β  Route Β 53 EC2 Β  Instances EL B EC2 Β  Instances ELB 0% 100% DynamoDB MySQL Β  RDS Instance ElastiCache Cache Β  Node Blue-Β­Green Β Deployment
  • 74. Auto Β  Scaling Β  Group V1 ELB Amazon Β  Relational Β  Database Β  Service Β (RDS) Red-Β­Black Β Deployment
  • 75. Auto Β  Scaling Β  Group V1 Auto Β Scaling Β  Group V2 ELB Amazon Β  Relational Β  Database Β  Service Β (RDS) UAT Red-Β­Black Β Deployment
  • 76. Auto Β  Scaling Β  Group V1 Auto Β Scaling Β  Group V2 ELB Amazon Β  Relational Β  Database Β  Service Β (RDS) ALM | Β Red-Β­Black Β Deployment
  • 77. Auto Β Scaling Β  Group V2 ELB Amazon Β  Relational Β  Database Β  Service Β (RDS) Red-Β­Black Β Deployment
  • 78. Monitoring Β & Β Metrics Β : Β The Β DevOps Β Pulse β€’ Track Β every Β resource Β possible β€’ Alert Β on Β services, availability, Β and response Β times β€’ Capture, Β learn, Β and Β improve β€’ Share Β access Β with Β everyone Β on Β the Β team β€’ Plan metrics Β and Β monitoring Β into Β the Β lifecycle
  • 81. Where Β do Β I Β go Β from Β here? β€’ Collect Β Metrics. Β Graph Β anything Β that Β moves β€’ Log Β everything, Β Centralize Β logging, Β Log Β  Analytics β€’ Infrastructure Β as Β Code β€’ Automated Β configuration Β management β€’ One Β click Β environment Β creation β€’ CI-Β­CD Β pipelines β€’ Automated Β testing