I apologize if this needs to be split into two questions, but I'm trying to set up a static site using S3, a CloudFront distribution, and a Route53 domain. If I try to access laszloffy.com, I receive a DNS_PROBE_FINISHED_NXDOMAIN error. If I try www.laszloffy.com, I get an XML 'Access Denied' error.
Below is my current configuration
Route53 records:
- laszloffy.com - NS
- laszloffy.com - SOA
- *.laszloffy.com - A - routes to Cloudfront distro
- *.laszloffy.com - AAAA - routes to https.....cloudfront.net
- ___.laszloffy.com - CNAME - routes to ____.acm-validations.aws
CloudFront Distro:
Alternate domain names:
- *.laszloffy.com
- laszloffy.com
Default root object - index.html
Origin:
- domain: slaszloffy-devops-resume.s3.us-east-2.amazonaws.com
- path: /index.html
- OAC
Error page: 403 to /index.html/200 status code
Function: appends index.html to requests that don't included file name or extension in URL
S3 Bucket
static site hosting: OFF
bucket policy:
"Version": "2012-10-17",
"Id": "PolicyForCloudFrontPrivateContent",
"Statement": [
{
"Sid": "AllowCloudFrontServicePrincipal",
"Effect": "Allow",
"Principal": {
"Service": "cloudfront.amazonaws.com"
},
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::slaszloffy-devops-resume/*",
"Condition": {
"StringEquals": {
"AWS:SourceArn": "arn:aws:cloudfront::107900886402:distribution/E1LP8SF6WAC8XK"
}
}
}
]
}
I've been looking through resources like this answer, and the AWS documentation, and it feels like I've got everything configured correctly, but obviously I'm missing something. Would love the community's assistance!