SlideShare a Scribd company logo
1 of 29
Download to read offline
© 2016, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Adhiraj Singh | Sr. Product Manager | AWS Elastic Beanstalk
06/21/2016
AWS Elastic Beanstalk (EB)
Running Microservices and Docker
Agenda
• Elastic Beanstalk vs DIY
• How to use Elastic Beanstalk
• Multi-Container Docker with AWS Elastic Beanstalk
• Recently added features
• Customer Feature - Sean O’Brien (Prezi)
Developer Challenges
• Complexity of deploying code, provisioning
and managing infrastructure
• Expertise and time needed to manage and
configure servers, databases, load
balancers, firewalls, and networks
• How to automate application scaling
What is Elastic Beanstalk?
AWS Elastic Beanstalk is an easy-to-use service for
deploying and scaling web applications and services.
AWS Elastic Beanstalk vs. Do It Yourself
Your code
HTTP Server
Application Server
Language Interpreter
Operating System
Host
Elastic Beanstalk configures each
EC2 instance in your
environment with the components
necessary to run applications for
the selected platform.
Focus on building your
application
Provided by you
Provided and managed by AWS Elastic Beanstalk (EB)
On-instance configuration
AWS Elastic Beanstalk vs. Do It Yourself
• Preconfigured Infrastructure
• Single Instance (Dev, Low Cost)
• Load Balanced, Auto Scaling (Production)
• Web & Worker tiers
• Elastic Beanstalk provisions necessary
infrastructure resources such as the load
balancer, auto scaling group, security
groups, database (optional), etc.
• Provides a unique domain name for your
application
(e.g.: youapp.regionx.elasticbeanstalk.com)
Infrastructure stack
Common Use Cases
• Websites
• API backends
• Mobile backends
• Asynchronous workers
Customers
Elastic Beanstalk Benefits
Fast & simple
to begin
Developer
productivity
Impossible
to outgrow
Complete
resource control
No additional charge to use.
You only pay for underlying AWS resources (i.e.: EC2 instances, S3, etc.)
How do I get started with Elastic Beanstalk?
Information required to deploy application
01
02
03
04
Region
Stack (container) type
Single Instance
Load Balanced with
auto-scaling
OR
Database (RDS) Optional
Your code
Supported Platforms
Building applications with Elastic Beanstalk
Service Repos:
/myapp
/myapp/browserClient
/myapp/browserServer
/myapp/androidUI
/myapp/api
/myapp/notifications
/myapp/adminPortal
Application: api
Environment
prod-api V1
Environment
dev-api V1.1
Environment
browserClient V2
Environment
browserClient V2.1
Environment
dev-api V1.2
Environment
browserClient V3
Application: browser
How to deploy applications
1. Via AWS Management Console
2. Via AWS Toolkit for Eclipse and Visual
Studio IDE
3. Via AWS SDK’s and CLI
4. Via EB command line interface
$ eb deploy
Deploy Sample Application (EB CLI)
Initial application deployment workflow
$ git clone
https://github.com/awslabs/eb-
node-express-sample.git
Download sample application02
$ eb init
Create your Elastic Beanstalk app03
Follow the prompts to configure the
environment
04
05 Create the resources and launch the
application
$ eb create
$ pip install --upgrade awsebcli
Install the AWS Elastic Beanstalk
command line interface (EB CLI)
01
Update Sample Application (EB CLI)
Update application workflow
Update your code01
$ git add .
$ git commit –m “v2.0”
$ eb deploy
Add & commit code to repository02
Open application once deployment
completes.
03
$ eb open
Docker with AWS Elastic Beanstalk
Docker Platform Configurations
• Single Container Docker
• Multi-Container Docker
Multi Container: Architecture
• Each environment has its own ECS Cluster
• Supports a single ECS Task definition per environment
• The ECS Task is defined in the Dockerrun.aws.json file
• Uses a flood scheduling mechanism
• Provides out of the box auto scaling for ECS Tasks
Elastic Beanstalk Environment
Auto Scaling Group / ECS Cluster
Instance 1 Instance 2
app1.elasticbeanstalk.com
Elastic Load
Balancing
Container 2Container 1
Container 3
Container 2Container 1
Container 3
Multi Container: Dockerrun.aws.json
{
"AWSEBDockerrunVersion": 2,
"volumes": [
{
"name": "node-app",
"host": {
"sourcePath": "/var/app/current/node-app"
}
},
{
"name": "tomcat-app",
"host": {
"sourcePath": "/var/app/current/tomcat-app"
}
}
],
"containerDefinitions": [
{
"name": "node-app",
"image": "node:0.12",
"essential": true,
"memory": 128,
"portMappings": [
{
"hostPort": 80,
"containerPort": 8000
}
],
"command": [
"/bin/bash",
"/usr/src/app/run.sh"
],
"mountPoints": [
{
"sourceVolume": "node-app",
"containerPath": "/usr/src/app"
}
]
},
{
"name": "tomcat-app",
"image": "tomcat:8.0",
"essential": true,
"memory": 256,
"portMappings": [
{
"hostPort": 8080,
"containerPort": 8080
}
],
"mountPoints": [
{
"sourceVolume": "awseb-logs-tomcat-app",
"containerPath": "/usr/local/tomcat/logs"
},
{
"sourceVolume": "tomcat-app",
"containerPath": "/usr/local/tomcat/webapps/ROOT",
"readOnly": true
}
]
}
]
}
Multi Container requires version 2
Multi Container with Elastic Beanstalk : Demo
Nginx Proxy Example
Code at: https://github.com/awslabs/eb-docker-nginx-proxy
Benefits of using Multi-Container Docker with
Elastic Beanstalk
• Automation of capacity provisioning, load balancing,
scaling, and application health monitoring
• One stop management of your application in an
environment that supports range of services that are
integrated with Elastic Beanstalk, including but not
limited to VPC, RDS, and IAM.
New Features
Recently added features
• Support for EC2 Container Registry - Learn more
• Managed Updates - Learn more
• New deployment options – Learn more
Questions?
How to get in touch with the EB team?
AWS Elastic Beanstalk Forum:
https://forums.aws.amazon.com/forum.jspa?forumID=86
Twitter:
@aws_eb
Thank You!
Don’t Forget Evaluations!
Multi Container: Virtual Hosts Example
Code at: https://github.com/awslabs/eb-docker-virtual-hosting
Elastic Beanstalk Environment
Auto Scaling Group / ECS Cluster
Instance 1 Instance 2
80
Container 1
Container 2
Nginx
Container 1
Container 2
Nginx
container1.app1.elasticbeanstalk.com
container2.app1.elasticbeanstalk.com
Elastic Load
Balancing
Multi Container:
Multiple Ports Example
Code at: https://github.com/awslabs/eb-docker-multiple-ports
Elastic Beanstalk Environment
Auto Scaling Group / ECS Cluster
Instance 1 Instance 2
Node.js Node.js
Tomcat
80
8080 Tomcat
app1.elasticbeanstalk.com:80
app1.elasticbeanstalk.com:8080
Elastic Load
Balancing

More Related Content

What's hot

What's hot (20)

Amazon services ec2
Amazon services ec2Amazon services ec2
Amazon services ec2
 
(DVO401) Deep Dive into Blue/Green Deployments on AWS
(DVO401) Deep Dive into Blue/Green Deployments on AWS(DVO401) Deep Dive into Blue/Green Deployments on AWS
(DVO401) Deep Dive into Blue/Green Deployments on AWS
 
Architecting for High Availability
Architecting for High AvailabilityArchitecting for High Availability
Architecting for High Availability
 
Become an IAM Policy Ninja
Become an IAM Policy NinjaBecome an IAM Policy Ninja
Become an IAM Policy Ninja
 
Getting Started with AWS Lambda and Serverless
Getting Started with AWS Lambda and ServerlessGetting Started with AWS Lambda and Serverless
Getting Started with AWS Lambda and Serverless
 
Amazon API Gateway
Amazon API GatewayAmazon API Gateway
Amazon API Gateway
 
Getting Started with AWS Compute Services
Getting Started with AWS Compute ServicesGetting Started with AWS Compute Services
Getting Started with AWS Compute Services
 
Deep dive ECS & Fargate Deep Dive
Deep dive ECS & Fargate Deep DiveDeep dive ECS & Fargate Deep Dive
Deep dive ECS & Fargate Deep Dive
 
Intro to Amazon ECS
Intro to Amazon ECSIntro to Amazon ECS
Intro to Amazon ECS
 
AWS Elastic Beanstalk
AWS Elastic BeanstalkAWS Elastic Beanstalk
AWS Elastic Beanstalk
 
데브옵스 엔지니어를 위한 신규 운영 서비스 - 김필중, AWS 개발 전문 솔루션즈 아키텍트 / 김현민, 메가존클라우드 솔루션즈 아키텍트 :...
데브옵스 엔지니어를 위한 신규 운영 서비스 - 김필중, AWS 개발 전문 솔루션즈 아키텍트 / 김현민, 메가존클라우드 솔루션즈 아키텍트 :...데브옵스 엔지니어를 위한 신규 운영 서비스 - 김필중, AWS 개발 전문 솔루션즈 아키텍트 / 김현민, 메가존클라우드 솔루션즈 아키텍트 :...
데브옵스 엔지니어를 위한 신규 운영 서비스 - 김필중, AWS 개발 전문 솔루션즈 아키텍트 / 김현민, 메가존클라우드 솔루션즈 아키텍트 :...
 
Deep dive into AWS IAM
Deep dive into AWS IAMDeep dive into AWS IAM
Deep dive into AWS IAM
 
IDC 서버 몽땅 AWS로 이전하기 위한 5가지 방법 - 윤석찬 (AWS 테크에반젤리스트)
IDC 서버 몽땅 AWS로 이전하기 위한 5가지 방법 - 윤석찬 (AWS 테크에반젤리스트) IDC 서버 몽땅 AWS로 이전하기 위한 5가지 방법 - 윤석찬 (AWS 테크에반젤리스트)
IDC 서버 몽땅 AWS로 이전하기 위한 5가지 방법 - 윤석찬 (AWS 테크에반젤리스트)
 
Module 2: Core AWS Compute and Storage Services - Virtual AWSome Day June 2018
Module 2: Core AWS Compute and Storage Services - Virtual AWSome Day June 2018Module 2: Core AWS Compute and Storage Services - Virtual AWSome Day June 2018
Module 2: Core AWS Compute and Storage Services - Virtual AWSome Day June 2018
 
AWS CloudFormation Masterclass
AWS CloudFormation MasterclassAWS CloudFormation Masterclass
AWS CloudFormation Masterclass
 
Accelerating App Development with AWS Amplify
Accelerating App Development with AWS AmplifyAccelerating App Development with AWS Amplify
Accelerating App Development with AWS Amplify
 
SEC306 Using Microsoft Active Directory Across On-Premises and AWS Cloud Wind...
SEC306 Using Microsoft Active Directory Across On-Premises and AWS Cloud Wind...SEC306 Using Microsoft Active Directory Across On-Premises and AWS Cloud Wind...
SEC306 Using Microsoft Active Directory Across On-Premises and AWS Cloud Wind...
 
AWSome Day Online Conference 2019 - Module 5 AWS Pricing and Support.pdf
AWSome Day Online Conference 2019 - Module 5 AWS Pricing and Support.pdfAWSome Day Online Conference 2019 - Module 5 AWS Pricing and Support.pdf
AWSome Day Online Conference 2019 - Module 5 AWS Pricing and Support.pdf
 
Deep Dive on AWS Lambda
Deep Dive on AWS LambdaDeep Dive on AWS Lambda
Deep Dive on AWS Lambda
 
Behind the Scenes: Exploring the AWS Global Network (NET305) - AWS re:Invent ...
Behind the Scenes: Exploring the AWS Global Network (NET305) - AWS re:Invent ...Behind the Scenes: Exploring the AWS Global Network (NET305) - AWS re:Invent ...
Behind the Scenes: Exploring the AWS Global Network (NET305) - AWS re:Invent ...
 

Similar to AWS Elastic Beanstalk - Running Microservices and Docker

Managing Docker & ECS Based Applications with AWS Elastic Beanstalk - DevDay ...
Managing Docker & ECS Based Applications with AWS Elastic Beanstalk - DevDay ...Managing Docker & ECS Based Applications with AWS Elastic Beanstalk - DevDay ...
Managing Docker & ECS Based Applications with AWS Elastic Beanstalk - DevDay ...
Amazon Web Services
 

Similar to AWS Elastic Beanstalk - Running Microservices and Docker (20)

Running Microservices and Docker on AWS Elastic Beanstalk - August 2016 Month...
Running Microservices and Docker on AWS Elastic Beanstalk - August 2016 Month...Running Microservices and Docker on AWS Elastic Beanstalk - August 2016 Month...
Running Microservices and Docker on AWS Elastic Beanstalk - August 2016 Month...
 
AWS Elastic Beanstalk運作微服務與Docker
AWS Elastic Beanstalk運作微服務與Docker AWS Elastic Beanstalk運作微服務與Docker
AWS Elastic Beanstalk運作微服務與Docker
 
Managing Docker & ECS Based Applications with AWS Elastic Beanstalk - DevDay ...
Managing Docker & ECS Based Applications with AWS Elastic Beanstalk - DevDay ...Managing Docker & ECS Based Applications with AWS Elastic Beanstalk - DevDay ...
Managing Docker & ECS Based Applications with AWS Elastic Beanstalk - DevDay ...
 
AWS Elastic Beanstalk: Running Multi-Container Docker Applications - DevDay L...
AWS Elastic Beanstalk: Running Multi-Container Docker Applications - DevDay L...AWS Elastic Beanstalk: Running Multi-Container Docker Applications - DevDay L...
AWS Elastic Beanstalk: Running Multi-Container Docker Applications - DevDay L...
 
Running Microservices and Docker with AWS Elastic Beanstalk
Running Microservices and Docker with AWS Elastic BeanstalkRunning Microservices and Docker with AWS Elastic Beanstalk
Running Microservices and Docker with AWS Elastic Beanstalk
 
Deploy, Manage, and Scale your Apps with AWS Elastic Beanstalk
Deploy, Manage, and Scale your Apps with AWS Elastic BeanstalkDeploy, Manage, and Scale your Apps with AWS Elastic Beanstalk
Deploy, Manage, and Scale your Apps with AWS Elastic Beanstalk
 
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container DayECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
 
Amazon EC2 Container Service: Manage Docker-Enabled Apps in EC2
Amazon EC2 Container Service: Manage Docker-Enabled Apps in EC2Amazon EC2 Container Service: Manage Docker-Enabled Apps in EC2
Amazon EC2 Container Service: Manage Docker-Enabled Apps in EC2
 
A 60-mn tour of AWS compute (March 2016)
A 60-mn tour of AWS compute (March 2016)A 60-mn tour of AWS compute (March 2016)
A 60-mn tour of AWS compute (March 2016)
 
Amazon EC2 Container Service: Manage Docker-Enabled Apps in EC2
Amazon EC2 Container Service: Manage Docker-Enabled Apps in EC2Amazon EC2 Container Service: Manage Docker-Enabled Apps in EC2
Amazon EC2 Container Service: Manage Docker-Enabled Apps in EC2
 
Distribua, gerencie e escale suas aplicações com o aws elastic beanstalk
Distribua, gerencie e escale suas aplicações com o aws elastic beanstalkDistribua, gerencie e escale suas aplicações com o aws elastic beanstalk
Distribua, gerencie e escale suas aplicações com o aws elastic beanstalk
 
Shipping logs to splunk from a container in aws howto
Shipping logs to splunk from a container in aws howtoShipping logs to splunk from a container in aws howto
Shipping logs to splunk from a container in aws howto
 
Tech connect aws
Tech connect  awsTech connect  aws
Tech connect aws
 
Amazon ECS – Production Docker at Scale
Amazon ECS – Production Docker at ScaleAmazon ECS – Production Docker at Scale
Amazon ECS – Production Docker at Scale
 
Docker on AWS
Docker on AWSDocker on AWS
Docker on AWS
 
AWS April Webinar Series - Getting Started with Amazon EC2 Container Service
AWS April Webinar Series - Getting Started with Amazon EC2 Container ServiceAWS April Webinar Series - Getting Started with Amazon EC2 Container Service
AWS April Webinar Series - Getting Started with Amazon EC2 Container Service
 
Deep Dive:EC2 Container Service
Deep Dive:EC2 Container ServiceDeep Dive:EC2 Container Service
Deep Dive:EC2 Container Service
 
AWS July Webinar Series-Deploying and Scaling Web Application with AWS Elasti...
AWS July Webinar Series-Deploying and Scaling Web Application with AWS Elasti...AWS July Webinar Series-Deploying and Scaling Web Application with AWS Elasti...
AWS July Webinar Series-Deploying and Scaling Web Application with AWS Elasti...
 
Agile Deployment using Git and AWS Elastic Beanstalk
Agile Deployment using Git and AWS Elastic BeanstalkAgile Deployment using Git and AWS Elastic Beanstalk
Agile Deployment using Git and AWS Elastic Beanstalk
 
A 60-minute tour of AWS Compute (November 2016)
A 60-minute tour of AWS Compute (November 2016)A 60-minute tour of AWS Compute (November 2016)
A 60-minute tour of AWS Compute (November 2016)
 

More from Amazon 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 AWS
Amazon 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 Deck
Amazon Web Services
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
Amazon 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
 

More from 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...
 
Come costruire un'architettura Serverless nel Cloud AWS
Come costruire un'architettura Serverless nel Cloud AWSCome costruire un'architettura Serverless nel Cloud AWS
Come costruire un'architettura Serverless nel Cloud AWS
 

Recently uploaded

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Recently uploaded (20)

Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 

AWS Elastic Beanstalk - Running Microservices and Docker

  • 1. © 2016, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Adhiraj Singh | Sr. Product Manager | AWS Elastic Beanstalk 06/21/2016 AWS Elastic Beanstalk (EB) Running Microservices and Docker
  • 2.
  • 3. Agenda • Elastic Beanstalk vs DIY • How to use Elastic Beanstalk • Multi-Container Docker with AWS Elastic Beanstalk • Recently added features • Customer Feature - Sean O’Brien (Prezi)
  • 4. Developer Challenges • Complexity of deploying code, provisioning and managing infrastructure • Expertise and time needed to manage and configure servers, databases, load balancers, firewalls, and networks • How to automate application scaling
  • 5. What is Elastic Beanstalk? AWS Elastic Beanstalk is an easy-to-use service for deploying and scaling web applications and services.
  • 6. AWS Elastic Beanstalk vs. Do It Yourself Your code HTTP Server Application Server Language Interpreter Operating System Host Elastic Beanstalk configures each EC2 instance in your environment with the components necessary to run applications for the selected platform. Focus on building your application Provided by you Provided and managed by AWS Elastic Beanstalk (EB) On-instance configuration
  • 7. AWS Elastic Beanstalk vs. Do It Yourself • Preconfigured Infrastructure • Single Instance (Dev, Low Cost) • Load Balanced, Auto Scaling (Production) • Web & Worker tiers • Elastic Beanstalk provisions necessary infrastructure resources such as the load balancer, auto scaling group, security groups, database (optional), etc. • Provides a unique domain name for your application (e.g.: youapp.regionx.elasticbeanstalk.com) Infrastructure stack
  • 8. Common Use Cases • Websites • API backends • Mobile backends • Asynchronous workers
  • 10. Elastic Beanstalk Benefits Fast & simple to begin Developer productivity Impossible to outgrow Complete resource control No additional charge to use. You only pay for underlying AWS resources (i.e.: EC2 instances, S3, etc.)
  • 11. How do I get started with Elastic Beanstalk?
  • 12. Information required to deploy application 01 02 03 04 Region Stack (container) type Single Instance Load Balanced with auto-scaling OR Database (RDS) Optional Your code Supported Platforms
  • 13. Building applications with Elastic Beanstalk Service Repos: /myapp /myapp/browserClient /myapp/browserServer /myapp/androidUI /myapp/api /myapp/notifications /myapp/adminPortal Application: api Environment prod-api V1 Environment dev-api V1.1 Environment browserClient V2 Environment browserClient V2.1 Environment dev-api V1.2 Environment browserClient V3 Application: browser
  • 14. How to deploy applications 1. Via AWS Management Console 2. Via AWS Toolkit for Eclipse and Visual Studio IDE 3. Via AWS SDK’s and CLI 4. Via EB command line interface $ eb deploy
  • 15. Deploy Sample Application (EB CLI) Initial application deployment workflow $ git clone https://github.com/awslabs/eb- node-express-sample.git Download sample application02 $ eb init Create your Elastic Beanstalk app03 Follow the prompts to configure the environment 04 05 Create the resources and launch the application $ eb create $ pip install --upgrade awsebcli Install the AWS Elastic Beanstalk command line interface (EB CLI) 01
  • 16. Update Sample Application (EB CLI) Update application workflow Update your code01 $ git add . $ git commit –m “v2.0” $ eb deploy Add & commit code to repository02 Open application once deployment completes. 03 $ eb open
  • 17. Docker with AWS Elastic Beanstalk
  • 18. Docker Platform Configurations • Single Container Docker • Multi-Container Docker
  • 19. Multi Container: Architecture • Each environment has its own ECS Cluster • Supports a single ECS Task definition per environment • The ECS Task is defined in the Dockerrun.aws.json file • Uses a flood scheduling mechanism • Provides out of the box auto scaling for ECS Tasks Elastic Beanstalk Environment Auto Scaling Group / ECS Cluster Instance 1 Instance 2 app1.elasticbeanstalk.com Elastic Load Balancing Container 2Container 1 Container 3 Container 2Container 1 Container 3
  • 20. Multi Container: Dockerrun.aws.json { "AWSEBDockerrunVersion": 2, "volumes": [ { "name": "node-app", "host": { "sourcePath": "/var/app/current/node-app" } }, { "name": "tomcat-app", "host": { "sourcePath": "/var/app/current/tomcat-app" } } ], "containerDefinitions": [ { "name": "node-app", "image": "node:0.12", "essential": true, "memory": 128, "portMappings": [ { "hostPort": 80, "containerPort": 8000 } ], "command": [ "/bin/bash", "/usr/src/app/run.sh" ], "mountPoints": [ { "sourceVolume": "node-app", "containerPath": "/usr/src/app" } ] }, { "name": "tomcat-app", "image": "tomcat:8.0", "essential": true, "memory": 256, "portMappings": [ { "hostPort": 8080, "containerPort": 8080 } ], "mountPoints": [ { "sourceVolume": "awseb-logs-tomcat-app", "containerPath": "/usr/local/tomcat/logs" }, { "sourceVolume": "tomcat-app", "containerPath": "/usr/local/tomcat/webapps/ROOT", "readOnly": true } ] } ] } Multi Container requires version 2
  • 21. Multi Container with Elastic Beanstalk : Demo Nginx Proxy Example Code at: https://github.com/awslabs/eb-docker-nginx-proxy
  • 22. Benefits of using Multi-Container Docker with Elastic Beanstalk • Automation of capacity provisioning, load balancing, scaling, and application health monitoring • One stop management of your application in an environment that supports range of services that are integrated with Elastic Beanstalk, including but not limited to VPC, RDS, and IAM.
  • 24. Recently added features • Support for EC2 Container Registry - Learn more • Managed Updates - Learn more • New deployment options – Learn more
  • 25. Questions? How to get in touch with the EB team? AWS Elastic Beanstalk Forum: https://forums.aws.amazon.com/forum.jspa?forumID=86 Twitter: @aws_eb
  • 28. Multi Container: Virtual Hosts Example Code at: https://github.com/awslabs/eb-docker-virtual-hosting Elastic Beanstalk Environment Auto Scaling Group / ECS Cluster Instance 1 Instance 2 80 Container 1 Container 2 Nginx Container 1 Container 2 Nginx container1.app1.elasticbeanstalk.com container2.app1.elasticbeanstalk.com Elastic Load Balancing
  • 29. Multi Container: Multiple Ports Example Code at: https://github.com/awslabs/eb-docker-multiple-ports Elastic Beanstalk Environment Auto Scaling Group / ECS Cluster Instance 1 Instance 2 Node.js Node.js Tomcat 80 8080 Tomcat app1.elasticbeanstalk.com:80 app1.elasticbeanstalk.com:8080 Elastic Load Balancing