🔰 HIGH AVAILABILITY ARCHITECTURE WITH AWS CLI 🔰

🔰 HIGH AVAILABILITY ARCHITECTURE WITH AWS CLI 🔰

Hello connections........!!!!

Presenting my new article on High Availability Architecture with AWS CLI. The architecture includes:

🔅 Web server configured on EC2 Instance

🔅 Document Root(/var/www/html) made persistent by mounting on EBS Block Device

🔅 Static objects used in code such as pictures stored in S3

🔅 Setting up Content Delivery Network using CloudFront and using the origin domain as S3 bucket. 

🔅 Finally place the CloudFront URL on the webapp code for security and low latency.

Cloudfront -

Cloudfront is a CDN (Content Delivery Network). It retrieves data from Amazon S3 bucket and distributes it to multiple data center locations. It delivers the data through a network of data centers called edge locations. The nearest edge location is routed when the user requests for data, resulting in lowest latency, low network traffic, fast access to data, etc.

Configuring Web server On AWS

  1. Create and launch web server on AWS
No alt text provided for this image
No alt text provided for this image
No alt text provided for this image

2. Now configure the web server on your instance

No alt text provided for this image
No alt text provided for this image
No alt text provided for this image

3. Now we need to add the rules for firewall to access our web server. The port number used for HTTP is 80 shown as follows:

No alt text provided for this image
No alt text provided for this image

4. Now try to access your web server:

No alt text provided for this image

Now we know that if our OS corrupts somehow then data present on our web server also gets corrupt. So to resolve this issue we can keep our data in EBS VOLUME instead of "root" directory.

5. Create an EBS Volume having partitions and then mount is to our folder containing html file.

No alt text provided for this image
No alt text provided for this image
No alt text provided for this image
  • Creating a partition in attached EBS
No alt text provided for this image
No alt text provided for this image
  • Format the created partition
No alt text provided for this image
  • Mount the partition to folder containing .html file
No alt text provided for this image
  • The .html file contains:
No alt text provided for this image

Now one thing to note is that the durability and availability of EBS is less and hence data can be lost. That means the static data such as pictures, PDF etc will be lost. So to resolve this we use the storage having high durability and availability of data - S3 Bucket.

6. Create a S3 Bucket and add your data in it.

aws s3api create-bucket --bucket awsbucketforweb--region ap-south-1 --create-bucket-configuration LocationConstraint=ap-south-1

No alt text provided for this image
No alt text provided for this image

and make it public.

No alt text provided for this image
  • Now add this link of S3 bucket in your .html code as shown:
No alt text provided for this image

7. Now finally create a Cloudfront distribution

No alt text provided for this image
No alt text provided for this image
No alt text provided for this image
No alt text provided for this image

Our cloud front is successful created.

Let’s open the web Server :

Finally our all steps are done, remaining one step is we have insert this cloud front url in our web page and open our page in the browser.

No alt text provided for this image

Now our web page is created successfully using cloudfront.

Hope you liked it...😊

Thank You!!✌

To view or add a comment, sign in

More articles by Jyoti Panjwani

  • HELM CHART FOR JENKINS

    What is Helm? Helm is the ”The Kubernetes package manager”. It is a command-line tool that enables you to create and…

  • CONTINUOUS DELIVERY OF ANDROID APPS WITH JENKINS

    What is Jenkins? Jenkins is a self-contained, open source automation server which can be used to automate all sorts of…

    1 Comment
  • Is it Possible to Run GUI Based Applications inside Docker Container?

    🔰 𝘊𝘰𝘯𝘵𝘢𝘪𝘯𝘦𝘳𝘪𝘻𝘢𝘵𝘪𝘰𝘯 𝘩𝘢𝘴 𝘵𝘶𝘳𝘯𝘦𝘥 𝘰𝘶𝘵 𝘵𝘰 𝘣𝘦 𝘢 𝘣𝘰𝘰𝘯 𝘧𝘰𝘳 𝘵𝘩𝘦 𝘵𝘦𝘤𝘩…

  • HOW BOSCH USES AZURE KUBERNETES SERVICE?

    WHAT IS KUBERNETES? Kubernetes is a portable, extensible, open source platform for container orchestration. It allows…

  • INDUSTRY USE CASES OF NEURAL NETWORK

    WHAT IS NEURAL NETWORK?🤔 A neural network is a series of algorithms that endeavors to recognize underlying…

  • LAUNCHING WORDPRESS WITH AMAZON RDS

    What is AWS-RDS? Amazon Relational Database Service (Amazon RDS) makes it easy to set up, operate, and scale a…

  • RESTARTING HTTPD SERVICES - HANDLERS

    ARTH - Task 11 👨🏻💻 Task Description📄 🔰 11.3 Restarting HTTPD Service is not idempotence in nature and also…

  • ANSIBLE - ONE STEP TO SOLUTION 🤓

    Working in IT, we're likely doing the same tasks over and over😒. What if you could solve problems once and then…

  • PYTHON AUTOMATION SCRIPT

    Hello connections, presenting my new article on Python Automation Script which includes integration of various…

  • BENEFITS OF AI/ML AND HOW GOOGLE IS USING IT ?

    Have you ever heard the term AI/ML?? These are the most trending words now a days. Everyone is talking about these…

Others also viewed

Explore content categories