Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in AWS by (12.9k points)

I am using amazon s3 bucket as the image server. And I want to use a subdomain of my site, how to address this bucket. eg: a picture is now in: "https:/ /s3-sa-east-1.amazonaws.com/nomeBucket/pasta/img.png", and I access it through this same link.

Would that it were so: imagens.mydomain.com.br / folder / img.png Is there any way I can do this? appoint a subdomain address to a bucket? I've tried the amazon route 53, as CNAME. I tried this: https:/ /s3-sa-east-1.amazonaws.com/nomeBucket/

I took the test yesterday, but apparently it did not work. Someone already did something similar, and / or know how to help me?

Note: I'm using nginx. also need to configure it for subdomain?

Thank you

1 Answer

0 votes
by (18.2k points)

Make sure that the name of the bucket matches your custom domain name and then set up that domain as the CNAME.

In your case the custom domain name is imagens.mydomain.com.br so your CNAME should look like:

imagens.mydomain.com.br.s3.amazonaws.com

You can refer to the official documentation to learn more: https://docs.aws.amazon.com/AmazonS3/latest/dev/VirtualHosting.html

Related questions

0 votes
1 answer
asked Feb 8, 2020 in AWS by Amenda (1.4k points)
Want to get 50% Hike on your Salary?

Learn how we helped 50,000+ professionals like you !

0 votes
1 answer

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...