Reputation: 2179
I'm almost a newbie in what respects to amazon buckets and instances, and what I have to do now is a custom error page for error 404. What is shown now is the default error page that shows an non-user-friendly XML telling that the file was not found.
Any ideas of a nice way to make this?
Upvotes: 12
Views: 10237
Reputation: 21
If you place CloudFront in front of S3 (your traffic costs will be lower) and it also allows you a far more fine-grained approach to how handling any errors (not just 404 errors)
Upvotes: 2
Reputation: 70339
I found the documentation to be extremely unclear. It says "provide this custom error document", which leaves me asking, "but how do I provide it?" It's in the S3 console, under the Properties tab, under "Static website hosting". But, you won't see it until you select the huge radio button beside "Use this bucket to host a website"
Upvotes: 3
Reputation: 179094
This is explained in the documentation.
You can optionally provide a custom error document with a user-friendly error message and with additional help. You provide this custom error document as part of adding website configuration to your bucket. Amazon S3 returns your custom error document for only the HTTP 4XX class of error codes.
— http://docs.aws.amazon.com/AmazonS3/latest/dev/CustomErrorDocSupport.html
Upvotes: -1