SlideShare uma empresa Scribd logo
1 de 110
© 2015, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
8/1/2017
A Tale of Two Pizzas
Accelerating Software Delivery with AWS Developer Tools
https://secure.flickr.com/photos/mgifford/4525333972
Why are we
here today?
What we'll cover
What is DevOps?
The Amazon DevOps story
AWS Code Services
AWS DevOps Portfolio
Software moves
faster today
Why does DevOps matter?
30xMore Frequent
Deployments
200xShorter Lead Times
60xFewer Failures
168xFaster Recovery
What is DevOps?
What is DevOps?
• Cultural philosophies
• Practices
• Tools
DevOps Culture
• Dev & Ops coming together
• No more “silos”
• Shared responsibility
• Ownership
• Visibility and communication
DevOps Practices
• Microservices
• Moving away from “monolithic” application
architecture to many individual services
DevOps Practices
• Continuous Integration
• Continuous Delivery & Deployment
DevOps Practices
• Infrastructure as Code
• Model your AWS resources using code
DevOps Practices
• Monitoring and Logging
• Track and analyze metrics and logs
• Understand real-time performance of
infrastructure and application
Reliability
Benefits of DevOps
Speed
Scale
Rapid DeliveryImproved Collaboration
Security
A look back at
development at
Amazon..
https://secure.flickr.com/photos/pixelthing/15806918992/
2001
Development transformation at Amazon: 2001-2009
2009
monolithic
application + teams
microservices + 2 pizza teams
Things went much
better under this
model and teams
were releasing faster
than ever, but we felt
that we could still
improve.
In 2009, we
ran a study to
find out where
inefficiencies
might still exist
We were just waiting.
WaitWrite
Code WaitBuild
Code WaitDeploy
to Test
Deploy
to
Prod
We were just waiting.
WaitWrite
Code WaitBuild
Code WaitDeploy
to Test
Deploy
to
Prod
Mins Days Mins Days Mins Days Mins
We were just waiting.
WaitWrite
Code WaitBuild
Code WaitDeploy
to Test
Deploy
to
Prod
Weeks
Mins Days Mins Days Mins Days Mins
We were just waiting.
WaitWrite
Code WaitBuild
Code WaitDeploy
to Test
Deploy
to
Prod
Weeks
Mins Days Mins Days Mins Days Mins
We built tools to
automate our software
release process
https://secure.flickr.com/photos/lindseygee/5894617854/
Automated actions and
transitions; from check-
in to production
Development benefits:
• Faster
• Safer
• Simplification &
standardization
• Visualization of the
process
Pipelines
This has continued to work out really well:
In 2014:
• Thousands of service teams across Amazon
• Building microservices
• Practicing continuous delivery
• Many environments (staging, beta, production)
50 million deploys
This has continued to work out really well:
Every year at Amazon, we perform a survey of all our
software developers. The 2014 results found only one
development tool/service could be correlated statistically
with happier developers:
Our pipelines service!
continuous delivery == happier developers!
Where do you
?
• Integration
tests with
other systems
• Load testing
• UI tests
• Penetration
testing
Release processes have four major phases
Source Build Test Production
• Check-in
source code
such as .java
files.
• Peer review
new code
• Compile code
• Unit tests
• Style checkers
• Code metrics
• Create
container
images
• Deployment
to production
environments
Release processes levels
Source Build Test Production
Continuous integration
Continuous delivery
Continuous deployment
AWS Code Services
AWS CodePipeline AWS CodeCommit AWS CodeBuildAWS CodeDeployAWS CodeStar
AWS Code Services
Source Build Test Production
Software Release Steps:
AWS Code Services
Source Build Test Production
Software Release Steps:
AWS CodeCommit
AWS Code Services
Source Build Test Production
Software Release Steps:
AWS CodeBuild
AWS Code Services
Source Build Test Production
Third Party
Tooling
Software Release Steps:
AWS Code Services
Source Build Test Production
Software Release Steps:
AWS CodeDeploy
Source Build Test Production
Third Party
Tooling
AWS CodeCommit AWS CodeBuild AWS CodeDeploy
AWS CodePipeline
AWS Code Services
Software Release Steps:
AWS Code Services
Source Build Test Production
Third Party
Tooling
Software Release Steps:
AWS CodeCommit AWS CodeBuild AWS CodeDeploy
AWS CodePipeline
AWS CodeStar
Amazon CloudWatch
AWS CloudTrail
Monitoring
& Logging
AWS DevOps Portfolio
AWS CodeCommit
AWS CodeDeploy
AWS CodePipeline
Software Development and
Continuous Delivery Toolchain
AWS CloudFormation
AWS OpsWorks
AWS Config
Infrastructure
as Code
AWS CodeBuild
AWS CodeStar
AWS OpsWorks for
Chef Automate
AWS X-Ray
Build & test your
application
https://secure.flickr.com/photos/spenceyc/7481166880
Fully managed build service that compiles source code,
runs tests, and produces software packages
Scales continuously and processes multiple builds
concurrently
You can provide custom build environments suited to
your needs via Docker images
Only pay by the minute for the compute resources you
use
Launched with CodePipeline and Jenkins integration
AWS CodeBuild
How does it work?
1. Downloads source code
2. Executes commands configured in the buildspec in
temporary compute containers (created fresh on every
build)
3. Streams the build output to the service console and
CloudWatch logs
4. Uploads the generated artifact to an S3 bucket
How can I automate my release process with CodeBuild?
• Integrated with AWS CodePipeline for CI/CD
• Easily pluggable (API/CLI driven)
• Bring your own build environments
• Create Docker images containing tools you need
• Open source Jenkins plugin
• Use CodeBuild as the workers off of a Jenkins master
buildspec.yml Example
version: 0.1
environment_variables:
plaintext:
JAVA_HOME: "/usr/lib/jvm/java-8-openjdk-amd64"
phases:
install:
commands:
- apt-get update -y
- apt-get install -y maven
pre_build:
commands:
- echo Nothing to do in the pre_build phase...
build:
commands:
- echo Build started on `date`
- mvn install
post_build:
commands:
- echo Build completed on `date`
artifacts:
type: zip
files:
- target/messageUtil-1.0.jar
discard-paths: yes
buildspec.yml Example
version: 0.1
environment_variables:
plaintext:
JAVA_HOME: "/usr/lib/jvm/java-8-openjdk-amd64"
phases:
install:
commands:
- apt-get update -y
- apt-get install -y maven
pre_build:
commands:
- echo Nothing to do in the pre_build phase...
build:
commands:
- echo Build started on `date`
- mvn install
post_build:
commands:
- echo Build completed on `date`
artifacts:
type: zip
files:
- target/messageUtil-1.0.jar
discard-paths: yes
• Variables to be used by phases of
build
• Examples for what you can do in
the phases of a build:
• You can install packages or run
commands to prepare your
environment in ”install”.
• Run syntax checking,
commands in “pre_build”.
• Execute your build
tool/command in “build”
• Test your app further or ship a
container image to a repository
in post_build
• Create and store an artifact in S3
Building Your Code
“Building” code typically refers to languages that
require compiled binaries:
• .NET languages: C#, F#, VB.net, etc.
• Java and JVM languages: Java, Scala,
JRuby
• Go
• iOS languages: Swift, Objective-C
We also refer to the process of creating Docker
container images as “building” the image. EC2
No Building Required!
Many languages don’t require building. These
are considered interpreted languages:
• PHP
• Ruby
• Python
• Node.js
You can just deploy your code!
EC2
Testing Your Code
Testing is both a science and an art form!
Goals for testing your code:
• Want to confirm desired functionality
• Catch programming syntax errors
• Standardize code patterns and format
• Reduce bugs due to non-desired application
usage and logic failures
• Make applications more secure
Where to Focus Your Tests:
UI
Service
Unit 70%
20%
10%
What service and release step corresponds with which tests?
UI
Service
Unit
Third Party
Tooling
AWS CodeBuild
BuildTest
Pricing
• Pay by the Minute
• Three compute types differentiated by the amount of
memory and CPU resources:
• Free tier of 100 build minutes
Compute instance type Memory (GB) vCPU Price per build minute ($)
build.general1.small 3 2 0.005
build.general1.medium 7 4 0.010
build.general1.large 15 8 0.020
*As of January 20 2017
Deploying your
applications
https://secure.flickr.com/photos/simononly/15386966677
Automates code deployments to any instance
Handles the complexity of updating your
applications
Avoid downtime during application deployment
Rollback automatically if failure detected
Deploy to Amazon EC2 or on-premises
servers, in any language and on any operating
system
Integrates with third-party tools and AWS
AWS CodeDeploy
appspec.yml Example
version: 0.0
os: linux
files:
- source: /
destination: /var/www/html
permissions:
- object: /var/www/html
pattern: “*.html”
owner: root
group: root
mode: 755
hooks:
ApplicationStop:
- location: scripts/deregister_from_elb.sh
BeforeInstall:
- location: scripts/install_dependencies.sh
ApplicationStart:
- location: scripts/start_httpd.sh
ValidateService:
- location: scripts/test_site.sh
- location: scripts/register_with_elb.sh
appspec.yml Example
version: 0.0
os: linux
files:
- source: /
destination: /var/www/html
permissions:
- object: /var/www/html
pattern: “*.html”
owner: root
group: root
mode: 755
hooks:
ApplicationStop:
- location: scripts/deregister_from_elb.sh
BeforeInstall:
- location: scripts/install_dependencies.sh
ApplicationStart:
- location: scripts/start_httpd.sh
ValidateService:
- location: scripts/test_site.sh
- location: scripts/register_with_elb.sh
• Remove/add instance to ELB
• Install dependency packages
• Start Apache
• Confirm successful deploy
• More!
• Send application files to one
directory and configuration
files to another
• Set specific permissions on
specific directories & files
v2 v2 v2 v2 v2 v2
one at a time
half at a time
all at once
v2 v2 v2 v1 v1 v1
v2 v1 v1 v1 v1 v1 Agent Agent
Dev Deployment group
OR
Prod Deployment group
Agent
AgentAgent
Agent Agent
Agent
Choose Deployment Speed and Group
Orchestrating build and
deploy with a pipeline
https://www.flickr.com/photos/seattlemunicipalarchives/12504672623/
Continuous delivery service for fast and
reliable application updates
Model and visualize your software release
process
Builds, tests, and deploys your code every time
there is a code change
Integrates with third-party tools and AWS
AWS CodePipeline
Source
Source
GitHub
Build
CodeBuild
AWS CodeBuild
Deploy
JavaApp
Elastic Beanstalk
Pipeline
Stage
Action
Transition
CodePipeline
MyApplication
Build
CodeBuild
AWS CodeBuild
NotifyDevelopers
Lambda
Parallel actions
Source
Source
GitHub
CodePipeline
MyApplication
Deploy
JavaApp
Elastic Beanstalk
Build
CodeBuild
AWS CodeBuild
NotifyDevelopers
Lambda
TestAPI
Runscope
Sequential actions
Deploy
JavaApp
Elastic Beanstalk
Source
Source
GitHub
CodePipeline
MyApplication
Build
CodeBuild
AWS CodeBuild
Staging-Deploy
JavaApp
Elastic Beanstalk
Prod-Deploy
JavaApp
Elastic Beanstalk
QATeamReview
Manual Approval
Manual Approvals
Review
CodePipeline
MyApplication
Secure, scalable, and managed Git source
control
Use standard Git tools
Scalability, availability, and durability of
Amazon S3
Encryption at rest with customer-specific keys
No repo size limit
Post commit hooks to call out to SNS/Lambda
AWS CodeCommit
Source control in the cloud
Secure Fully
managed
High
availability
Store
anything
AWS CodeCommit
git pull/push CodeCommit
Git objects in
Amazon S3
Git index in
Amazon
DynamoDB
Encryption key
in AWS KMS
SSH or HTTPS
$ 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
Same Git experience
Pricing
CodeCommit
$1 per active user per month (first 5 users free)
CodePipeline
$1 per active pipeline per month (first 1 free)
CodeDeploy
Free to deploy to Amazon EC2
$0.02 per update to on-prem server
CodeBuild
Compute Instance
Type
Memory(GB) vCPU Price per build minute
($)
Small 3 2 0.005
Medium 7 4 0.010
Large 15 8 0.020
Introducing: AWS CodeStar
Quickly develop, build, and deploy applications on AWS
Start developing on AWS in minutes
Work across your team, securely
Manage software delivery easily
Choose from a variety of project templates
AWS CodeStar
Project Templates for EC2, Lambda, and Elastic Beanstalk
AWS CodeStar
Pre- Configured Continuous Delivery Toolchain
AWS CodeStar
Easily connect your favorite IDE
AWS CodeStar
Set up secure team access in a few clicks
AWS CodeStar
Unified Dashboard – Managing Delivery Pipeline and Issue Tracking
AWS CodeStar
Unified Dashboard – Application Activity and Commit History
AWS Code featured customers
THANK YOU
Appendix
General Best Practices used by Amazon Developers
CI/CD is a MUST!
Everything that is code (application, infrastructure,
documentation) goes into a repository
Start with continuous delivery (“gated” promotion)
and build up to continuous deployment once
evidence of a high-level of excellence in testing is
clear
Deploy to canaries, test, deploy to an AZ, test,
deploy to a Region, test
General Best Practices used by Amazon Developers (contd.)
Code Reviews are one of the best mechanisms for
“good” code:
• Does this code look clean and can someone else
understand it?
• Is the design of it meeting the expectations of its needs?
Style checkers
• Will someone else in the company be able to
update/fix/maintain this code?
Auto-rollbacks can be the quickest recovery
mechanism after failure
• Rollback first, then debug what went wrong with
logs/graphs/etc.
AWS Code integrated partners
AWS DevOps consulting partners
DEMO!
Demo:
1. Start with a repository (github.com/awslabs/aws-
codedeploy-sample-tomcat)
2. Add buildspec.yml
3. Create CodePipeline pipeline with a Source and Build
stage
4. Do a build
5. Add a deploy stage
6. Do a full execution of the pipeline
Demo:
 Start with a repository (github.com/awslabs/aws-
codedeploy-sample-tomcat)
 Add buildspec.yml
 Create CodePipeline pipeline with a Source and Build
stage
 Do a build
• Add a deploy stage
• Do a full execution of the pipeline
Demo:
 Start with a repository (github.com/awslabs/aws-
codedeploy-sample-tomcat)
 Add buildspec.yml
 Create CodePipeline pipeline with a Source and Build
stage
 Do a build
 Add a deploy stage
 Do a full execution of the pipeline
General Best Practices used by Amazon Developers
• CI/CD is a MUST!
• Commit frequently
• Builds on every commit
• Build once in a given execution flow
• Deploy to a running environment for further testing
General Best Practices used by Amazon Developers
• CI/CD is a MUST!
• Commit frequently
• Builds on every commit
• Build once in a given execution flow
• Deploy to a running environment for further testing
• Everything that is code (application, infrastructure, documentation)
goes into a repository
• If its not in a repository, it doesn’t go into Production environments!
General Best Practices used by Amazon Developers
• CI/CD is a MUST!
• Commit frequently
• Builds on every commit
• Build once in a given execution flow
• Deploy to a running environment for further testing
• Everything that is code (application, infrastructure, documentation)
goes into a repository
• If its not in a repository, it doesn’t go into production environments!
• Start with continuous delivery (“gated” promotion) and build up to
continuous deployment once evidence of a high-level of excellence in
testing is clear
General Best Practices used by Amazon Developers
• CI/CD is a MUST!
• Commit frequently
• Builds on every commit
• Build once in a given execution flow
• Deploy to a running environment for further testing
• Everything that is code (application, infrastructure, documentation)
goes into a repository
• If its not in a repository, it doesn’t go into production environments!
• Start with continuous delivery (“gated” promotion) and build up to
continuous deployment once evidence of a high-level of excellence in
testing is clear
• Deploy to canaries, test, deploy to an AZ, test, deploy to a Region,
test
General Best Practices used by Amazon Developers (cont.)
• Code Reviews are one of the best mechanisms for “good” code:
• Does this code look clean and can someone else understand it?
• Is the design of it meeting the expectations of its needs?
• Are there better/easier ways to do this same thing?
General Best Practices used by Amazon Developers (cont.)
• Code Reviews are one of the best mechanisms for “good” code:
• Does this code look clean and can someone else understand it?
• Is the design of it meeting the expectations of its needs?
• Are there better/easier ways to do this same thing?
• Style checkers
• Will someone else in the company be able to update/fix/maintain this code?
General Best Practices used by Amazon Developers (cont.)
• Code Reviews are one of the best mechanisms for “good” code:
• Does this code look clean and can someone else understand it?
• Is the design of it meeting the expectations of its needs?
• Are there better/easier ways to do this same thing?
• Style checkers
• Will someone else in the company be able to update/fix/maintain this code?
• Auto-rollbacks can be the quickest recovery mechanism after failure
• Rollback first, then debug what went wrong with logs/graphs/etc.
General Best Practices used by Amazon Developers (cont.)
• Code Reviews are one of the best mechanisms for “good” code:
• Does this code look clean and can someone else understand it?
• Is the design of it meeting the expectations of its needs?
• Are there better/easier ways to do this same thing?
• Style checkers
• Will someone else in the company be able to update/fix/maintain this code?
• Auto-rollbacks can be the quickest recovery mechanism after failure
• Rollback first, then debug what went wrong with logs/graphs/etc.
• Thorough dashboards
• What is happening now?
• What ”normal” looks like typically over some period of time?
• What do I do if this graph looks wrong/an alarm has been triggered?
• What events can I correlate with a move in a graph?
Code* Tips and Tricks
• All Code* products can(and should) be provisioned and managed
with AWS CloudFormation!
• You could literally store the CloudFormation templates that provision
your Code* resources in CodeCommit and update them via
CodePipeline (It’s like Code* Inception!)
• Deep integration with IAM. You can assign permissions on who can
commit code, approve manual approvals, deploy to certain
deployment groups and more!
• Integrate with AWS Lambda to do almost anything:
• CodeCommit has Repository Triggers
• CodeDeploy has Event Notifications
• CodePipeline has native Lambda invoke
AWS CodePipeline AWS CodeCommit AWS CodeBuildAWS CodeDeploy
aws.amazon.com/devops
AWS DevOps Blog
?
https://secure.flickr.com/photos/dullhunk/202872717/

Mais conteúdo relacionado

Mais procurados

Swift Programming Language
Swift Programming LanguageSwift Programming Language
Swift Programming LanguageCihad Horuzoğlu
 
From Spring Framework 5.3 to 6.0
From Spring Framework 5.3 to 6.0From Spring Framework 5.3 to 6.0
From Spring Framework 5.3 to 6.0VMware Tanzu
 
Introduction to Swagger
Introduction to SwaggerIntroduction to Swagger
Introduction to SwaggerKnoldus Inc.
 
Object-Oriented Programming in Java.pdf
Object-Oriented Programming in Java.pdfObject-Oriented Programming in Java.pdf
Object-Oriented Programming in Java.pdfBharath Choudhary
 
Clean Code II - Dependency Injection
Clean Code II - Dependency InjectionClean Code II - Dependency Injection
Clean Code II - Dependency InjectionTheo Jungeblut
 
Java concurrency - Thread pools
Java concurrency - Thread poolsJava concurrency - Thread pools
Java concurrency - Thread poolsmaksym220889
 
Ppt of java and java script
Ppt of java and java scriptPpt of java and java script
Ppt of java and java scriptkonkumuttisravan
 
Validate your entities with symfony validator and entity validation api
Validate your entities with symfony validator and entity validation apiValidate your entities with symfony validator and entity validation api
Validate your entities with symfony validator and entity validation apiRaffaele Chiocca
 
Spring Cloud Function: Where We Were, Where We Are, and Where We’re Going
Spring Cloud Function: Where We Were, Where We Are, and Where We’re GoingSpring Cloud Function: Where We Were, Where We Are, and Where We’re Going
Spring Cloud Function: Where We Were, Where We Are, and Where We’re GoingVMware Tanzu
 
Spring framework-tutorial
Spring framework-tutorialSpring framework-tutorial
Spring framework-tutorialvinayiqbusiness
 
Reactive programming with rx java
Reactive programming with rx javaReactive programming with rx java
Reactive programming with rx javaCongTrung Vnit
 

Mais procurados (20)

Swift Programming Language
Swift Programming LanguageSwift Programming Language
Swift Programming Language
 
From Spring Framework 5.3 to 6.0
From Spring Framework 5.3 to 6.0From Spring Framework 5.3 to 6.0
From Spring Framework 5.3 to 6.0
 
Spring batch overivew
Spring batch overivewSpring batch overivew
Spring batch overivew
 
Introduction to Swagger
Introduction to SwaggerIntroduction to Swagger
Introduction to Swagger
 
Object-Oriented Programming in Java.pdf
Object-Oriented Programming in Java.pdfObject-Oriented Programming in Java.pdf
Object-Oriented Programming in Java.pdf
 
Clean Code II - Dependency Injection
Clean Code II - Dependency InjectionClean Code II - Dependency Injection
Clean Code II - Dependency Injection
 
Java concurrency - Thread pools
Java concurrency - Thread poolsJava concurrency - Thread pools
Java concurrency - Thread pools
 
Swagger UI
Swagger UISwagger UI
Swagger UI
 
Top java script frameworks ppt
Top java script frameworks pptTop java script frameworks ppt
Top java script frameworks ppt
 
Introduction to JAVA
Introduction to JAVAIntroduction to JAVA
Introduction to JAVA
 
Makalah java
Makalah javaMakalah java
Makalah java
 
Ppt of java and java script
Ppt of java and java scriptPpt of java and java script
Ppt of java and java script
 
Validate your entities with symfony validator and entity validation api
Validate your entities with symfony validator and entity validation apiValidate your entities with symfony validator and entity validation api
Validate your entities with symfony validator and entity validation api
 
Optional in Java 8
Optional in Java 8Optional in Java 8
Optional in Java 8
 
Spring Cloud Function: Where We Were, Where We Are, and Where We’re Going
Spring Cloud Function: Where We Were, Where We Are, and Where We’re GoingSpring Cloud Function: Where We Were, Where We Are, and Where We’re Going
Spring Cloud Function: Where We Were, Where We Are, and Where We’re Going
 
Spring framework-tutorial
Spring framework-tutorialSpring framework-tutorial
Spring framework-tutorial
 
Core java
Core java Core java
Core java
 
Maven Introduction
Maven IntroductionMaven Introduction
Maven Introduction
 
Spring security
Spring securitySpring security
Spring security
 
Reactive programming with rx java
Reactive programming with rx javaReactive programming with rx java
Reactive programming with rx java
 

Semelhante a A Tale of Two Pizzas: Accelerating Software Delivery with AWS Developer Tools

ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...Amazon Web Services
 
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...Amazon Web Services
 
SRV312 DevOps on AWS: Building Systems to Deliver Faster
SRV312 DevOps on AWS: Building Systems to Deliver FasterSRV312 DevOps on AWS: Building Systems to Deliver Faster
SRV312 DevOps on AWS: Building Systems to Deliver FasterAmazon Web Services
 
DevOps on AWS: DevOps Day San Francisco
DevOps on AWS: DevOps Day San FranciscoDevOps on AWS: DevOps Day San Francisco
DevOps on AWS: DevOps Day San FranciscoAmazon Web Services
 
A Tale of Two Pizzas: Developer Tools at AWS - DevDay Los Angeles 2017
A Tale of Two Pizzas: Developer Tools at AWS - DevDay Los Angeles 2017A Tale of Two Pizzas: Developer Tools at AWS - DevDay Los Angeles 2017
A Tale of Two Pizzas: Developer Tools at AWS - DevDay Los Angeles 2017Amazon Web Services
 
A Tale of Two Pizzas: Accelerating Software Delivery with Developer Tools - D...
A Tale of Two Pizzas: Accelerating Software Delivery with Developer Tools - D...A Tale of Two Pizzas: Accelerating Software Delivery with Developer Tools - D...
A Tale of Two Pizzas: Accelerating Software Delivery with Developer Tools - D...Amazon Web Services
 
Announcing AWS CodeBuild - January 2017 Online Teck Talks
Announcing AWS CodeBuild - January 2017 Online Teck TalksAnnouncing AWS CodeBuild - January 2017 Online Teck Talks
Announcing AWS CodeBuild - January 2017 Online Teck TalksAmazon Web Services
 
A tale of two pizzas: Developer tools at AWS
A tale of two pizzas: Developer tools at AWSA tale of two pizzas: Developer tools at AWS
A tale of two pizzas: Developer tools at AWSAmazon Web Services
 
DevOps on AWS - Building Systems to Deliver Faster
DevOps on AWS - Building Systems to Deliver FasterDevOps on AWS - Building Systems to Deliver Faster
DevOps on AWS - Building Systems to Deliver FasterAmazon Web Services
 
Automate Software Deployments on EC2 with AWS CodeDeploy
Automate Software Deployments on EC2 with AWS CodeDeployAutomate Software Deployments on EC2 with AWS CodeDeploy
Automate Software Deployments on EC2 with AWS CodeDeployAmazon Web Services
 
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer ToolsDevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer ToolsAmazon Web Services
 
Dev Ops on AWS - Accelerating Software Delivery - AWS-Summit SG 2017
Dev Ops on AWS - Accelerating Software Delivery - AWS-Summit SG 2017Dev Ops on AWS - Accelerating Software Delivery - AWS-Summit SG 2017
Dev Ops on AWS - Accelerating Software Delivery - AWS-Summit SG 2017Amazon Web Services
 
ACDKOCHI19 - CI / CD using AWS Developer Tools
ACDKOCHI19 - CI / CD using AWS Developer ToolsACDKOCHI19 - CI / CD using AWS Developer Tools
ACDKOCHI19 - CI / CD using AWS Developer ToolsAWS User Group Kochi
 
DevOps on Windows: How to Deploy Complex Windows Workloads | AWS Public Secto...
DevOps on Windows: How to Deploy Complex Windows Workloads | AWS Public Secto...DevOps on Windows: How to Deploy Complex Windows Workloads | AWS Public Secto...
DevOps on Windows: How to Deploy Complex Windows Workloads | AWS Public Secto...Amazon Web Services
 
DevOps on AWS - Accelerating Software Delivery
DevOps on AWS - Accelerating Software DeliveryDevOps on AWS - Accelerating Software Delivery
DevOps on AWS - Accelerating Software DeliveryAmazon Web Services
 
Application Lifecycle Management
Application Lifecycle ManagementApplication Lifecycle Management
Application Lifecycle ManagementAmazon Web Services
 
LaunchingYourAppTheAmazonWay_SFStartupDay
LaunchingYourAppTheAmazonWay_SFStartupDayLaunchingYourAppTheAmazonWay_SFStartupDay
LaunchingYourAppTheAmazonWay_SFStartupDayAmazon Web Services
 
Continuous Deployment with Amazon Web Services
Continuous Deployment with Amazon Web ServicesContinuous Deployment with Amazon Web Services
Continuous Deployment with Amazon Web ServicesJulien SIMON
 

Semelhante a A Tale of Two Pizzas: Accelerating Software Delivery with AWS Developer Tools (20)

ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
 
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
 
SRV312 DevOps on AWS: Building Systems to Deliver Faster
SRV312 DevOps on AWS: Building Systems to Deliver FasterSRV312 DevOps on AWS: Building Systems to Deliver Faster
SRV312 DevOps on AWS: Building Systems to Deliver Faster
 
DevOps on AWS: DevOps Day San Francisco
DevOps on AWS: DevOps Day San FranciscoDevOps on AWS: DevOps Day San Francisco
DevOps on AWS: DevOps Day San Francisco
 
Developer Tools at AWS 2018.pdf
Developer Tools at AWS 2018.pdfDeveloper Tools at AWS 2018.pdf
Developer Tools at AWS 2018.pdf
 
A Tale of Two Pizzas: Developer Tools at AWS - DevDay Los Angeles 2017
A Tale of Two Pizzas: Developer Tools at AWS - DevDay Los Angeles 2017A Tale of Two Pizzas: Developer Tools at AWS - DevDay Los Angeles 2017
A Tale of Two Pizzas: Developer Tools at AWS - DevDay Los Angeles 2017
 
A Tale of Two Pizzas: Accelerating Software Delivery with Developer Tools - D...
A Tale of Two Pizzas: Accelerating Software Delivery with Developer Tools - D...A Tale of Two Pizzas: Accelerating Software Delivery with Developer Tools - D...
A Tale of Two Pizzas: Accelerating Software Delivery with Developer Tools - D...
 
Announcing AWS CodeBuild - January 2017 Online Teck Talks
Announcing AWS CodeBuild - January 2017 Online Teck TalksAnnouncing AWS CodeBuild - January 2017 Online Teck Talks
Announcing AWS CodeBuild - January 2017 Online Teck Talks
 
A tale of two pizzas: Developer tools at AWS
A tale of two pizzas: Developer tools at AWSA tale of two pizzas: Developer tools at AWS
A tale of two pizzas: Developer tools at AWS
 
DevOps on AWS - Building Systems to Deliver Faster
DevOps on AWS - Building Systems to Deliver FasterDevOps on AWS - Building Systems to Deliver Faster
DevOps on AWS - Building Systems to Deliver Faster
 
Automate Software Deployments on EC2 with AWS CodeDeploy
Automate Software Deployments on EC2 with AWS CodeDeployAutomate Software Deployments on EC2 with AWS CodeDeploy
Automate Software Deployments on EC2 with AWS CodeDeploy
 
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer ToolsDevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
 
Dev Ops on AWS - Accelerating Software Delivery - AWS-Summit SG 2017
Dev Ops on AWS - Accelerating Software Delivery - AWS-Summit SG 2017Dev Ops on AWS - Accelerating Software Delivery - AWS-Summit SG 2017
Dev Ops on AWS - Accelerating Software Delivery - AWS-Summit SG 2017
 
ACDKOCHI19 - CI / CD using AWS Developer Tools
ACDKOCHI19 - CI / CD using AWS Developer ToolsACDKOCHI19 - CI / CD using AWS Developer Tools
ACDKOCHI19 - CI / CD using AWS Developer Tools
 
DevOps on Windows: How to Deploy Complex Windows Workloads | AWS Public Secto...
DevOps on Windows: How to Deploy Complex Windows Workloads | AWS Public Secto...DevOps on Windows: How to Deploy Complex Windows Workloads | AWS Public Secto...
DevOps on Windows: How to Deploy Complex Windows Workloads | AWS Public Secto...
 
DevOps on AWS - Accelerating Software Delivery
DevOps on AWS - Accelerating Software DeliveryDevOps on AWS - Accelerating Software Delivery
DevOps on AWS - Accelerating Software Delivery
 
Application Lifecycle Management
Application Lifecycle ManagementApplication Lifecycle Management
Application Lifecycle Management
 
LaunchingYourAppTheAmazonWay_SFStartupDay
LaunchingYourAppTheAmazonWay_SFStartupDayLaunchingYourAppTheAmazonWay_SFStartupDay
LaunchingYourAppTheAmazonWay_SFStartupDay
 
Continuous Deployment with Amazon Web Services
Continuous Deployment with Amazon Web ServicesContinuous Deployment with Amazon Web Services
Continuous Deployment with Amazon Web Services
 
AWS Code Services
AWS Code ServicesAWS Code Services
AWS Code Services
 

Mais de Amazon Web Services

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Amazon Web Services
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Amazon Web Services
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateAmazon Web Services
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSAmazon Web Services
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Amazon Web Services
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Amazon Web Services
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...Amazon Web Services
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsAmazon Web Services
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareAmazon Web Services
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSAmazon Web Services
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAmazon Web Services
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareAmazon Web Services
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWSAmazon Web Services
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckAmazon Web Services
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without serversAmazon Web Services
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...Amazon Web Services
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceAmazon Web Services
 

Mais de Amazon Web Services (20)

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS Fargate
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWS
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot
 
Open banking as a service
Open banking as a serviceOpen banking as a service
Open banking as a service
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
 
Computer Vision con AWS
Computer Vision con AWSComputer Vision con AWS
Computer Vision con AWS
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatare
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e web
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWS
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch Deck
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
 
Fundraising Essentials
Fundraising EssentialsFundraising Essentials
Fundraising Essentials
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container Service
 

A Tale of Two Pizzas: Accelerating Software Delivery with AWS Developer Tools

  • 1. © 2015, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 8/1/2017 A Tale of Two Pizzas Accelerating Software Delivery with AWS Developer Tools
  • 3. What we'll cover What is DevOps? The Amazon DevOps story AWS Code Services AWS DevOps Portfolio
  • 5. Why does DevOps matter? 30xMore Frequent Deployments 200xShorter Lead Times 60xFewer Failures 168xFaster Recovery
  • 7. What is DevOps? • Cultural philosophies • Practices • Tools
  • 8. DevOps Culture • Dev & Ops coming together • No more “silos” • Shared responsibility • Ownership • Visibility and communication
  • 9. DevOps Practices • Microservices • Moving away from “monolithic” application architecture to many individual services
  • 10. DevOps Practices • Continuous Integration • Continuous Delivery & Deployment
  • 11. DevOps Practices • Infrastructure as Code • Model your AWS resources using code
  • 12. DevOps Practices • Monitoring and Logging • Track and analyze metrics and logs • Understand real-time performance of infrastructure and application
  • 13. Reliability Benefits of DevOps Speed Scale Rapid DeliveryImproved Collaboration Security
  • 14. A look back at development at Amazon.. https://secure.flickr.com/photos/pixelthing/15806918992/
  • 15. 2001 Development transformation at Amazon: 2001-2009 2009 monolithic application + teams microservices + 2 pizza teams
  • 16. Things went much better under this model and teams were releasing faster than ever, but we felt that we could still improve.
  • 17. In 2009, we ran a study to find out where inefficiencies might still exist
  • 18. We were just waiting. WaitWrite Code WaitBuild Code WaitDeploy to Test Deploy to Prod
  • 19. We were just waiting. WaitWrite Code WaitBuild Code WaitDeploy to Test Deploy to Prod Mins Days Mins Days Mins Days Mins
  • 20. We were just waiting. WaitWrite Code WaitBuild Code WaitDeploy to Test Deploy to Prod Weeks Mins Days Mins Days Mins Days Mins
  • 21. We were just waiting. WaitWrite Code WaitBuild Code WaitDeploy to Test Deploy to Prod Weeks Mins Days Mins Days Mins Days Mins
  • 22. We built tools to automate our software release process https://secure.flickr.com/photos/lindseygee/5894617854/
  • 23. Automated actions and transitions; from check- in to production Development benefits: • Faster • Safer • Simplification & standardization • Visualization of the process Pipelines
  • 24. This has continued to work out really well: In 2014: • Thousands of service teams across Amazon • Building microservices • Practicing continuous delivery • Many environments (staging, beta, production) 50 million deploys
  • 25. This has continued to work out really well: Every year at Amazon, we perform a survey of all our software developers. The 2014 results found only one development tool/service could be correlated statistically with happier developers: Our pipelines service! continuous delivery == happier developers!
  • 27. • Integration tests with other systems • Load testing • UI tests • Penetration testing Release processes have four major phases Source Build Test Production • Check-in source code such as .java files. • Peer review new code • Compile code • Unit tests • Style checkers • Code metrics • Create container images • Deployment to production environments
  • 28. Release processes levels Source Build Test Production Continuous integration Continuous delivery Continuous deployment
  • 29. AWS Code Services AWS CodePipeline AWS CodeCommit AWS CodeBuildAWS CodeDeployAWS CodeStar
  • 30. AWS Code Services Source Build Test Production Software Release Steps:
  • 31. AWS Code Services Source Build Test Production Software Release Steps: AWS CodeCommit
  • 32. AWS Code Services Source Build Test Production Software Release Steps: AWS CodeBuild
  • 33. AWS Code Services Source Build Test Production Third Party Tooling Software Release Steps:
  • 34. AWS Code Services Source Build Test Production Software Release Steps: AWS CodeDeploy
  • 35. Source Build Test Production Third Party Tooling AWS CodeCommit AWS CodeBuild AWS CodeDeploy AWS CodePipeline AWS Code Services Software Release Steps:
  • 36. AWS Code Services Source Build Test Production Third Party Tooling Software Release Steps: AWS CodeCommit AWS CodeBuild AWS CodeDeploy AWS CodePipeline AWS CodeStar
  • 37. Amazon CloudWatch AWS CloudTrail Monitoring & Logging AWS DevOps Portfolio AWS CodeCommit AWS CodeDeploy AWS CodePipeline Software Development and Continuous Delivery Toolchain AWS CloudFormation AWS OpsWorks AWS Config Infrastructure as Code AWS CodeBuild AWS CodeStar AWS OpsWorks for Chef Automate AWS X-Ray
  • 38. Build & test your application https://secure.flickr.com/photos/spenceyc/7481166880
  • 39. Fully managed build service that compiles source code, runs tests, and produces software packages Scales continuously and processes multiple builds concurrently You can provide custom build environments suited to your needs via Docker images Only pay by the minute for the compute resources you use Launched with CodePipeline and Jenkins integration AWS CodeBuild
  • 40. How does it work? 1. Downloads source code 2. Executes commands configured in the buildspec in temporary compute containers (created fresh on every build) 3. Streams the build output to the service console and CloudWatch logs 4. Uploads the generated artifact to an S3 bucket
  • 41. How can I automate my release process with CodeBuild? • Integrated with AWS CodePipeline for CI/CD • Easily pluggable (API/CLI driven) • Bring your own build environments • Create Docker images containing tools you need • Open source Jenkins plugin • Use CodeBuild as the workers off of a Jenkins master
  • 42. buildspec.yml Example version: 0.1 environment_variables: plaintext: JAVA_HOME: "/usr/lib/jvm/java-8-openjdk-amd64" phases: install: commands: - apt-get update -y - apt-get install -y maven pre_build: commands: - echo Nothing to do in the pre_build phase... build: commands: - echo Build started on `date` - mvn install post_build: commands: - echo Build completed on `date` artifacts: type: zip files: - target/messageUtil-1.0.jar discard-paths: yes
  • 43. buildspec.yml Example version: 0.1 environment_variables: plaintext: JAVA_HOME: "/usr/lib/jvm/java-8-openjdk-amd64" phases: install: commands: - apt-get update -y - apt-get install -y maven pre_build: commands: - echo Nothing to do in the pre_build phase... build: commands: - echo Build started on `date` - mvn install post_build: commands: - echo Build completed on `date` artifacts: type: zip files: - target/messageUtil-1.0.jar discard-paths: yes • Variables to be used by phases of build • Examples for what you can do in the phases of a build: • You can install packages or run commands to prepare your environment in ”install”. • Run syntax checking, commands in “pre_build”. • Execute your build tool/command in “build” • Test your app further or ship a container image to a repository in post_build • Create and store an artifact in S3
  • 44. Building Your Code “Building” code typically refers to languages that require compiled binaries: • .NET languages: C#, F#, VB.net, etc. • Java and JVM languages: Java, Scala, JRuby • Go • iOS languages: Swift, Objective-C We also refer to the process of creating Docker container images as “building” the image. EC2
  • 45. No Building Required! Many languages don’t require building. These are considered interpreted languages: • PHP • Ruby • Python • Node.js You can just deploy your code! EC2
  • 46. Testing Your Code Testing is both a science and an art form! Goals for testing your code: • Want to confirm desired functionality • Catch programming syntax errors • Standardize code patterns and format • Reduce bugs due to non-desired application usage and logic failures • Make applications more secure
  • 47. Where to Focus Your Tests: UI Service Unit 70% 20% 10%
  • 48. What service and release step corresponds with which tests? UI Service Unit Third Party Tooling AWS CodeBuild BuildTest
  • 49. Pricing • Pay by the Minute • Three compute types differentiated by the amount of memory and CPU resources: • Free tier of 100 build minutes Compute instance type Memory (GB) vCPU Price per build minute ($) build.general1.small 3 2 0.005 build.general1.medium 7 4 0.010 build.general1.large 15 8 0.020 *As of January 20 2017
  • 51. Automates code deployments to any instance Handles the complexity of updating your applications Avoid downtime during application deployment Rollback automatically if failure detected Deploy to Amazon EC2 or on-premises servers, in any language and on any operating system Integrates with third-party tools and AWS AWS CodeDeploy
  • 52. appspec.yml Example version: 0.0 os: linux files: - source: / destination: /var/www/html permissions: - object: /var/www/html pattern: “*.html” owner: root group: root mode: 755 hooks: ApplicationStop: - location: scripts/deregister_from_elb.sh BeforeInstall: - location: scripts/install_dependencies.sh ApplicationStart: - location: scripts/start_httpd.sh ValidateService: - location: scripts/test_site.sh - location: scripts/register_with_elb.sh
  • 53. appspec.yml Example version: 0.0 os: linux files: - source: / destination: /var/www/html permissions: - object: /var/www/html pattern: “*.html” owner: root group: root mode: 755 hooks: ApplicationStop: - location: scripts/deregister_from_elb.sh BeforeInstall: - location: scripts/install_dependencies.sh ApplicationStart: - location: scripts/start_httpd.sh ValidateService: - location: scripts/test_site.sh - location: scripts/register_with_elb.sh • Remove/add instance to ELB • Install dependency packages • Start Apache • Confirm successful deploy • More! • Send application files to one directory and configuration files to another • Set specific permissions on specific directories & files
  • 54. v2 v2 v2 v2 v2 v2 one at a time half at a time all at once v2 v2 v2 v1 v1 v1 v2 v1 v1 v1 v1 v1 Agent Agent Dev Deployment group OR Prod Deployment group Agent AgentAgent Agent Agent Agent Choose Deployment Speed and Group
  • 55. Orchestrating build and deploy with a pipeline https://www.flickr.com/photos/seattlemunicipalarchives/12504672623/
  • 56. Continuous delivery service for fast and reliable application updates Model and visualize your software release process Builds, tests, and deploys your code every time there is a code change Integrates with third-party tools and AWS AWS CodePipeline
  • 60. Build CodeBuild AWS CodeBuild Staging-Deploy JavaApp Elastic Beanstalk Prod-Deploy JavaApp Elastic Beanstalk QATeamReview Manual Approval Manual Approvals Review CodePipeline MyApplication
  • 61. Secure, scalable, and managed Git source control Use standard Git tools Scalability, availability, and durability of Amazon S3 Encryption at rest with customer-specific keys No repo size limit Post commit hooks to call out to SNS/Lambda AWS CodeCommit
  • 62. Source control in the cloud Secure Fully managed High availability Store anything
  • 63. AWS CodeCommit git pull/push CodeCommit Git objects in Amazon S3 Git index in Amazon DynamoDB Encryption key in AWS KMS SSH or HTTPS
  • 64. $ 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 Same Git experience
  • 65. Pricing CodeCommit $1 per active user per month (first 5 users free) CodePipeline $1 per active pipeline per month (first 1 free) CodeDeploy Free to deploy to Amazon EC2 $0.02 per update to on-prem server CodeBuild Compute Instance Type Memory(GB) vCPU Price per build minute ($) Small 3 2 0.005 Medium 7 4 0.010 Large 15 8 0.020
  • 66. Introducing: AWS CodeStar Quickly develop, build, and deploy applications on AWS Start developing on AWS in minutes Work across your team, securely Manage software delivery easily Choose from a variety of project templates
  • 67. AWS CodeStar Project Templates for EC2, Lambda, and Elastic Beanstalk
  • 68. AWS CodeStar Pre- Configured Continuous Delivery Toolchain
  • 69. AWS CodeStar Easily connect your favorite IDE
  • 70. AWS CodeStar Set up secure team access in a few clicks
  • 71. AWS CodeStar Unified Dashboard – Managing Delivery Pipeline and Issue Tracking
  • 72. AWS CodeStar Unified Dashboard – Application Activity and Commit History
  • 73. AWS Code featured customers
  • 76. General Best Practices used by Amazon Developers CI/CD is a MUST! Everything that is code (application, infrastructure, documentation) goes into a repository Start with continuous delivery (“gated” promotion) and build up to continuous deployment once evidence of a high-level of excellence in testing is clear Deploy to canaries, test, deploy to an AZ, test, deploy to a Region, test
  • 77. General Best Practices used by Amazon Developers (contd.) Code Reviews are one of the best mechanisms for “good” code: • Does this code look clean and can someone else understand it? • Is the design of it meeting the expectations of its needs? Style checkers • Will someone else in the company be able to update/fix/maintain this code? Auto-rollbacks can be the quickest recovery mechanism after failure • Rollback first, then debug what went wrong with logs/graphs/etc.
  • 80. DEMO!
  • 81. Demo: 1. Start with a repository (github.com/awslabs/aws- codedeploy-sample-tomcat) 2. Add buildspec.yml 3. Create CodePipeline pipeline with a Source and Build stage 4. Do a build 5. Add a deploy stage 6. Do a full execution of the pipeline
  • 82.
  • 83.
  • 84.
  • 85.
  • 86.
  • 87.
  • 88.
  • 89.
  • 90.
  • 91.
  • 92. Demo:  Start with a repository (github.com/awslabs/aws- codedeploy-sample-tomcat)  Add buildspec.yml  Create CodePipeline pipeline with a Source and Build stage  Do a build • Add a deploy stage • Do a full execution of the pipeline
  • 93.
  • 94.
  • 95.
  • 96.
  • 97.
  • 98. Demo:  Start with a repository (github.com/awslabs/aws- codedeploy-sample-tomcat)  Add buildspec.yml  Create CodePipeline pipeline with a Source and Build stage  Do a build  Add a deploy stage  Do a full execution of the pipeline
  • 99. General Best Practices used by Amazon Developers • CI/CD is a MUST! • Commit frequently • Builds on every commit • Build once in a given execution flow • Deploy to a running environment for further testing
  • 100. General Best Practices used by Amazon Developers • CI/CD is a MUST! • Commit frequently • Builds on every commit • Build once in a given execution flow • Deploy to a running environment for further testing • Everything that is code (application, infrastructure, documentation) goes into a repository • If its not in a repository, it doesn’t go into Production environments!
  • 101. General Best Practices used by Amazon Developers • CI/CD is a MUST! • Commit frequently • Builds on every commit • Build once in a given execution flow • Deploy to a running environment for further testing • Everything that is code (application, infrastructure, documentation) goes into a repository • If its not in a repository, it doesn’t go into production environments! • Start with continuous delivery (“gated” promotion) and build up to continuous deployment once evidence of a high-level of excellence in testing is clear
  • 102. General Best Practices used by Amazon Developers • CI/CD is a MUST! • Commit frequently • Builds on every commit • Build once in a given execution flow • Deploy to a running environment for further testing • Everything that is code (application, infrastructure, documentation) goes into a repository • If its not in a repository, it doesn’t go into production environments! • Start with continuous delivery (“gated” promotion) and build up to continuous deployment once evidence of a high-level of excellence in testing is clear • Deploy to canaries, test, deploy to an AZ, test, deploy to a Region, test
  • 103. General Best Practices used by Amazon Developers (cont.) • Code Reviews are one of the best mechanisms for “good” code: • Does this code look clean and can someone else understand it? • Is the design of it meeting the expectations of its needs? • Are there better/easier ways to do this same thing?
  • 104. General Best Practices used by Amazon Developers (cont.) • Code Reviews are one of the best mechanisms for “good” code: • Does this code look clean and can someone else understand it? • Is the design of it meeting the expectations of its needs? • Are there better/easier ways to do this same thing? • Style checkers • Will someone else in the company be able to update/fix/maintain this code?
  • 105. General Best Practices used by Amazon Developers (cont.) • Code Reviews are one of the best mechanisms for “good” code: • Does this code look clean and can someone else understand it? • Is the design of it meeting the expectations of its needs? • Are there better/easier ways to do this same thing? • Style checkers • Will someone else in the company be able to update/fix/maintain this code? • Auto-rollbacks can be the quickest recovery mechanism after failure • Rollback first, then debug what went wrong with logs/graphs/etc.
  • 106. General Best Practices used by Amazon Developers (cont.) • Code Reviews are one of the best mechanisms for “good” code: • Does this code look clean and can someone else understand it? • Is the design of it meeting the expectations of its needs? • Are there better/easier ways to do this same thing? • Style checkers • Will someone else in the company be able to update/fix/maintain this code? • Auto-rollbacks can be the quickest recovery mechanism after failure • Rollback first, then debug what went wrong with logs/graphs/etc. • Thorough dashboards • What is happening now? • What ”normal” looks like typically over some period of time? • What do I do if this graph looks wrong/an alarm has been triggered? • What events can I correlate with a move in a graph?
  • 107. Code* Tips and Tricks • All Code* products can(and should) be provisioned and managed with AWS CloudFormation! • You could literally store the CloudFormation templates that provision your Code* resources in CodeCommit and update them via CodePipeline (It’s like Code* Inception!) • Deep integration with IAM. You can assign permissions on who can commit code, approve manual approvals, deploy to certain deployment groups and more! • Integrate with AWS Lambda to do almost anything: • CodeCommit has Repository Triggers • CodeDeploy has Event Notifications • CodePipeline has native Lambda invoke AWS CodePipeline AWS CodeCommit AWS CodeBuildAWS CodeDeploy