A totally unrelated feature image that looks cool.
Fun with image filters Sharon Drummon

Access Denied When Accessing Cloudfront Distribution

I'm in the process of revamping my internet precense as well as my employer's websites.  Considering that the bulk of this stuff can be accomplished without a dynamic website I've turned to AWS Cloudfront distributions pulling from AWS S3 buckets for the bulk of my sites. Clearly I got this one working pretty well but I was running into an issue with some of the other sites I was standing up.  When I went to their domain I was receiving an "Access Denied" message.  

I searched Google and most of the "here's how to fix this issue" talked about IAM roles and access identities.  All of that was right but it was still giving me the access denied error.  Then, on a lark, I checked by going to the ./index.html file and it worked perfectly.  WTH, says I.

Yeah.  I had forgotten to add the Default Root Object.  *sigh.  It needs to be set to whatever the index file on your domain is going to be or else when you visit the domain name it'll throw the access denied message.

I hope this saves you some time.

This article was updated on March 4, 2021

Rob Tacey

Rob is the IT Systems Manager for a manufacturing automation company in Southwestern Ontario. It's great. He's a technologist focusing on information technology, IT security, and customer satisfaction. With over 20 years of experience in various IT roles, it might actually be worth reading some of his stuff.

Comments