Skip to content

Commit c6f1cba

Browse files
committed
Add to README: Requests to /es and redirecting to www
1 parent bcbc0b0 commit c6f1cba

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,11 @@ Check the [terraform](./terraform/) directory for more info.
3333

3434
**TODO:** add terraform-docs
3535

36-
### Requests to /es and redirecting non-www to www
36+
### Requests to /es and redirecting to www
3737

38-
Those type of requests are handled by [cdn_request_handler.js](./terraform/cdn_request_handler.js) in the CloudFront distribution.
38+
The CloudFront distribution is configured with [cdn_request_handler.js](./terraform/cdn_request_handler.js) to redirect root domain requests to `www` (e.g., domain.com -> www.domain.com). This is possible because `www` is added an alias to the distribution and to the ACM Certificate as a subject alternative name (SAN).
39+
40+
The handler also takes care of requests to `/es`. This is needed because CloudFront doesn't resolve `index.html` files in subdirectories, and `/es` is a subdirectory.
3941

4042
### About Route53 and DNS propagation
4143

0 commit comments

Comments
 (0)