1 Answer
- Newest
- Most votes
- Most comments
1
CloudFront supports the root of the origin that your distribution is directed towards, but it doesn't work for subdirectories.
If you want the CloudFront distribution to reach the subdirectory, then you can use Lambda@Edge (Extra charge).
Here is a blog with more information: https://aws.amazon.com/blogs/compute/implementing-default-directory-indexes-in-amazon-s3-backed-amazon-cloudfront-origins-using-lambdaedge/
answered a year ago
Relevant content
- Accepted Answerasked 2 years ago
- asked a year ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 3 months ago
- AWS OFFICIALUpdated 10 months ago
- AWS OFFICIALUpdated 2 years ago
Where is Cloudfront pointing to? EC2? S3? Could you provide screenshot of the Distribution?
You'll need to provide some additional information to help determine the root cause of the problem. What exactly do you mean by "it doesn't work?" Is there an error message or code? What do you see in your web server access logs?