AWS Innovate: Smart Deployment on AWS - Andy Kim
-
Upload
amazon-web-services-korea -
Category
Technology
-
view
399 -
download
0
Transcript of AWS Innovate: Smart Deployment on AWS - Andy Kim
![Page 1: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/1.jpg)
AWS로스마트하게소프트웨어배포하기
김일호, 솔루션즈아키텍트, 한국아마존웹서비스
![Page 2: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/2.jpg)
![Page 3: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/3.jpg)
~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
![Page 4: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/4.jpg)
Monolithic
Service-Oriented architectureAgilityMicroservice
![Page 5: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/5.jpg)
Better Communication~
Better productivity~
Effectiveness~
Decentralized~
Agility~
Ownership~
![Page 6: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/6.jpg)
Microservice development lifecycle
developers delivery pipelinesservices
releasetestbuild
releasetestbuild
releasetestbuild
releasetestbuild
releasetestbuild
![Page 7: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/7.jpg)
MonitorProvisionDeployTestBuildCode
Elastic Beanstalk
OpsWorks
Cloud
Watch
Cloud
Formation
Code
Deploy
Code
Commit
Code
Pipeline
![Page 8: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/8.jpg)
CodeCommit
![Page 9: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/9.jpg)
Source control in the cloud
Secure Fullymanaged
High availability
Storeanything
![Page 10: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/10.jpg)
AWS CodeCommit
• Use standard Git tools
• Scalability, availability, and durability of Amazon S3
• Encryption at rest with customer-specific keys
• No repo size limit
git pull/push CodeCommit
Git objects inAmazon S3
Git index inAmazon DynamoDB
Encryption keyin AWS KMS
SSH or HTTPS
![Page 11: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/11.jpg)
CodePipeline
![Page 12: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/12.jpg)
AWS CodePipeline
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 regoin3
![Page 13: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/13.jpg)
AWS CodePipeline
• Continuous Delivery and Release Automation
• Design your own workflow• Source-Code Checking• Building• Testing• Deploying
• Integration with partners and custom plugins
• Configure gates between stages• Time based vs manual approvals
• Visual editor and status monitoring
![Page 14: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/14.jpg)
CodePipeline example
https://blogs.aws.amazon.com/application-management/blog/tag/CodePipeline
![Page 15: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/15.jpg)
CodePipeline example
https://blogs.aws.amazon.com/application-management/blog/tag/CodePipeline
![Page 16: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/16.jpg)
CodeDeploy
![Page 17: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/17.jpg)
CodeDeploy
• Scale from 1 instance to thousands
• Deploy without downtime
• Centralize deployment control and monitoring
Staging
CodeDeployv1, v2, v3
Production
Dev
Applicationrevisions
Deployment groups
![Page 18: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/18.jpg)
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
![Page 19: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/19.jpg)
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
![Page 20: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/20.jpg)
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
![Page 21: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/21.jpg)
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
![Page 22: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/22.jpg)
Step 3: Deploy
aws deploy create-deployment \
--application-name MyApp \
--deployment-group-name TargetGroup \
--s3-location bucket=MyBucket,key=MyApp.zip
AWS CLI & SDKsAWS ConsoleCI / CD PartnersGitHub
![Page 23: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/23.jpg)
Deployment config – Choose speed
v2 v2 v2 v2 v2 v2 v2 v2All-at-onceMin. healthy hosts = 0
v2 v2 v2 v2 v1 v1 v1 v1Half-at-a-timeMin. healthy hosts = 50%
v2 v2 v1 v1 v1 v1 v1 v1[Custom]Min. healthy hosts = 75%
v2 v1 v1 v1 v1 v1 v1 v1One-at-a-timeMin. healthy hosts = 99%
![Page 24: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/24.jpg)
Rolling update – Deploy without downtime
v1v1 v1
Load Balancer
![Page 25: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/25.jpg)
Rolling update – Deploy without downtime
v1v2 v1
Load Balancer
![Page 26: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/26.jpg)
Rolling update – Deploy without downtime
v2v2 v1
Load Balancer
![Page 27: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/27.jpg)
Rolling update – Deploy without downtime
v2v2v2
Load Balancer
![Page 28: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/28.jpg)
Rolling update – Deploy without downtime
v2v2 v2
Load Balancer
![Page 29: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/29.jpg)
Health tracking – Catch deployment problems
v2v2 v2
Load Balancer
![Page 30: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/30.jpg)
Health tracking – Catch deployment problems
v3 v2 v2Stop
Load Balancer
![Page 31: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/31.jpg)
Health tracking – Catch deployment problems
v2v2 v2
Load Balancer
Rollback
![Page 32: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/32.jpg)
Health tracking – Catch deployment problems
v2v2 v2
Load Balancer
![Page 33: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/33.jpg)
Amazon
S3
Pro
d -
subnet
Web
serve
r
App
serve
r
Amazon
RDS
ELB
Production
Dev
-subnet
Auto Scaling group
Web
serve
r
Auto Scaling group
App
serve
r
Amazon
RDS
ELB
Development
Test -
subnet
Web
serve
r
App
serve
r
Amazon
RDS
ELB
Test
CodePipleline CodeDeployCodeCommit
Services- Highly available CloudWatch alarm
CloudTrail
CloudFormation
Elastic
Beanstalk
![Page 34: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/34.jpg)
Online Labs & Training
Gain confidence and hands-on experience with AWS.
Watch free Instructional Videos and explore Self-Paced Labs
Instructor Led Classes
Learn how to design, deploy and operate highly available, cost-
effective and secure applications on AWS in courses led by qualified
AWS instructors
Validate your technical expertise with AWS and use practice exams to help you
prepare for AWS Certification
AWS Certification
More info at http://aws.amazon.com/training
![Page 35: AWS Innovate: Smart Deployment on AWS - Andy Kim](https://reader031.fdocument.pub/reader031/viewer/2022030304/5878c4231a28ab26728b5a4d/html5/thumbnails/35.jpg)
Thank You for Attending AWS Innovate
We hope you found it interesting! Do provide us with your feedback for the session and complete the feedback form.
Let us know your thoughts of today’s event and how we can improve the event experience for you in the future.