So something weird happened, I’ve set up my AWS S3 bucket for static website hosting, and it all works perfectly fine, but whenever I go to plain domain (For example: ‘test.com’) It returns an XML file error, followed by dumping all the content in that XML. It’ll look like this, but the rest of the domains like ‘test.com/test’ does work.. I have index.html set as my index in my bucket, and everything seems to be properly configured. Any help?
Also, going to ‘test.com/index’ does in fact show the index fine, only when you go to ‘test.com’ does it give the XML error.
You have two problems:
- You’ve misconfigured the bucket ACL or policy to allow everyone to list the objects in the bucket.
How do you list the objects in a bucket? You go to the root of the REST endpoint of the bucket… so what you’re seeing is not an XML “error” — it’s a bucket listing.
This, in turn, reveals the second problem:
- You’ve configured your domain to point to the REST endpoint, not the web site hosting endpoint.
The web site hosting features are only available from the web site endpoints.