In this blog, we will demonstrate how to set up an AWS environment from scratch (for deploying an enterprise web application). We will demonstrate how to create and configure VPC, Subnets, EC2 instances, MySQL RDS, Elastic Load Balancer. Post that we will deploy a simple Spring Boot Application on this AWS environment with high availability.
Our aim in this blog in not to focus on the Spring Boot application and its deployment, but instead focus on setting up AWS for deploying an enterprise web application (which in our case happens to be a simple Spring Boot application).
So get ready to dive-in and get your hands dirty.
Table of Contents
- 1.0 What we want to do?
- 2.0 Prerequisites
- 3.0 Deployment Architecture
- 4.0 Creating VPC & Subnets
- 5.0 Setting up MySQL RDS
- 6.0 Setting up an EC2 Instances
- 6.1 Create an EC2 Instance
- 6.2 Setup Tomcat Application server on EC2
- 6.2.1 Connecting to EC2 Instance
- 6.2.2 Install Java
- 6.2.3 Download and Install Tomcat
- 6.2.4 Deploy Application war file
- 6.2.5 Configuring the Jhipster application to connect to our RDS Instance
- 6.2.6 Add startup Script for Tomcat Application
- 6.2.7 Testing Tomcat Application
- 6.2.8 Connection to MySQL Instance for running queries
- 6.3 Creating an Image of EC2 Instance
- 6.4 Creating additional EC2 from the AMI
- 7.0 Setting up Elastic Load Balancer (ELB)
- 8.0 Testing the application
Since this is a long blog, we have broken it into multiple parts
- Part 1 – Introduction and Full Table of Contents
- Part 2 – What we want to do, Prerequisites and Deployment Architecture
- Part 3 – Understanding VPC and Subnets, and how to create them
- Part 4 – Creating an instance of MySQL RDS
- Part 5 – Creating EC2 Instances, Installing Tomcat on it and deploying a Spring Boot application
- Part 6 – Creating an Image of EC2 Instance and then using the image to spawn multiple EC2 instances in different Availability zones
- Part 7 – Configuring an Elastic Load Balancer, and testing the application