“Think like a Cloud Architect”— Building a website using AWS

Arun Arunachalam
2 min readJan 25, 2021

Author: Arun Arunachalam Edited by: Lahari Arun

This article is meant for architects who are well versed at building solutions using traditional architecture standards and patterns and are in the process of transitioning to a modern cloud based environment.

Scenario: You just got a requirement to build and deploy a website using Amazon Web Services.

Here are the primary questions that will drive architecture choices:

  1. What type of website are we trying to build? Is it a static website or a dynamic website?
  2. Where are our customers located? Are they region specific or are they globally distributed? Are the customers really sensitive to latency?
  3. Do we need to support both root domain and subdomain access?
  4. Are there any audit requirements?

Here are some examples of how the answers to the above questions would drive the architecture choices:

  1. Static Web Site -> S3 (Simple Storage Service)

A more dynamic website can push us to leverage EC2 but for static website (SPA type applications), we should be looking at S3 service.

S3 (Simple Storage Service) was one of the primitive services built by AWS. It was originally introduced in 2006 and has come a long way.

S3 is like a replacement for the web server from a “traditional” architecture standpoint.

2. Global footprint and speed of content delivery -> Amazon Cloud Front

If our customers are globally distributed and are sensitive to latency, then we need to leverage Amazon Cloud Front which is a CDN service offered by AWS.

In a traditional enterprise environment, setting up a CDN would take months with the involvement of external vendors from CDN standpoint.

3. Remember www.example.com and example.com are not the same!

If we need to support the subdomain www in www.example.com by setting up the appropriate bucket in S3 and the name should be “www.example.com” and perform the necessary redirection to “example.com” S3 bucket.

4. Audit ->Access log

We want to know all the details about the activities that occur within the S3 bucket and CloudFront distribution. The logs can be sent to the S3 log file bucket directly.

The architecture for hosting a static website using S3 will look like this:

credit: https://insisivecloud.io/blogs/aws/statically-host-a-website-using-aws-s3

--

--