Reputation: 1
Hello i want to use my bucket to display a index or a redirect is that possible?
For example when i go to my bucket bucket1example.s3.amazonaws.com, i get AccessDenied error
<Error>
<Code>AccessDenied</Code>
<Message>Access Denied</Message>
<RequestId>42RP9K65G8T9EA7A</RequestId>
<HostId>
byYoD3naIjOi3aqwONTrAkOL2Basfdj29faPMz29sgofukHo15K987GIRClOuscJmzKX0S24EzM=
</HostId>
</Error>
But if i go to my file doc.html bucket1example.s3.amazonaws.com/doc.html i can see my file. Is there a way to display the Doc.html file with the url "bucket1example.s3.amazonaws.com"? Is possible when i visit bucket1example.s3.amazonaws.com automatically redirect to "doc.html"?
Upvotes: 0
Views: 177
Reputation: 1538
You have to enable static website hosting for the bucket and configure an index document
This AWS document can help you with the configuration.
https://docs.aws.amazon.com/AmazonS3/latest/userguide/IndexDocumentSupport.html
Upvotes: 3