title: How do I get all requests to a bucket in S3 to redirect to corresponding requests to another bucket in S3?
body: <p>I'm hosting a static website using Amazon's S3 file storage web service. The bucket I'm hosting it on is "www.dleybz.com" (to which I own the corresponding domain name). I also have the bucket "dleybz.com" set up on my account, and it's set to redirect requests to the index of the original bucket.</p>
  
  <p>Unfortunately, it's redirecting all request to the root of the original bucket. So while "www.dleybz.com/reddit.html" redirects to where it's supposed to, "dleybz.com/reddit.html" just redirects to "www.dleybz.com/index.html", whereas I would want it to redirect to "www.dleybz.com/reddit.html".</p>
  
  <p>One solution would be to simply clone all the files in the original bucket and store them in the second bucket, but this has disadvantages (having to upload to two buckets instead of just one every time a change is made, having to store twice as much data).</p>
  
  <p>Another would be to set up a corresponding redirection file, but that would require creating a new redirect html file for each file in the original bucket, which would be time-consuming.</p>
  
  <p><a href="http://docs.aws.amazon.com/AmazonS3/latest/dev/website-hosting-custom-domain-walkthrough.html" rel="nofollow">This Amazon guide</a> instructs users to simply select the "Redirect all requests to another host name" option and enter the name to direct users to. I've done this, but it results in the problem I'm currently having: all requests redirect to the root domain, instead of the corresponding web-address.</p>