Using Lambda@Edge to overcome limitations of static website hosting with S3 and Cloudfront
The problem This blog is a static website hosted in a S3 bucket which acts as an origin for a Cloudfront distribution. The article that you are currently reading is a post which is located on the URI path ‘/posts’. When I first deployed this website and I tried to access the posts which were displayed perfectly fine in my localhost, I came across the error below: