I want to dynamically route subdomains to S3 bucket folders. Whats the best way to achieve this?
Example:
I have a bucket called 'example' which has two folders, one called 'A' and another one called 'B'. Now I want to dynamically route a.example.com to folder 'A' and b.example.com to folder 'B'...and so on.
Hope this makes sense
Thanks
It does make sense, but you can't do it. You can configure S3 and DNS to route one hostname to one bucket, but not to just part of a bucket.
If, instead of folders, you were willing to use two different buckets, then it is easy to set up the redirection of the two hostnames to the two different buckets.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With