Hi! I'm making a social media (it's moreso a learning experience not anything serious) with a react frontend but the question here is one I think anyone who has made an app that handles displaying files from s3 or whatever can answer!
Right now after a lot of trial and error (I'm not the best with not so documented libraries but I'm getting better!) with waffle I can upload an avatar for a user, store it in aws and the db, and send the link back. I went to this link and I thought it would be as simple as now I have the file! I go to the link and it spouts out xml 99 percent sure Giving some "The bucket you are attempting to access must be addressed using the specified endpoint. Please send all future requests to this endpoint."
So at this point I'm a bit confused, I try searching things up but there seem to be little resources online on what's the proper way to do this, maybe I didn't search the right thing,
How should I deal with giving files off? I've never had to deal with something like this before so I'm really confused
There's CDNs, do I even use those yet? Should I make it so that only certain users have access to certain images, if yes, how within this system, do they just post request an image and I serve it, if yes then what about where I want a static link which is dealt with get so it's easy to pass a link around or so search engines can index it
With discord I can just go to https://media.discordapp.net/attachments/blahblahblah even if it's from another one of my friends dms and it's not even blocked! is this even good design, I guess it would be really hard to guess a link but still it's dm/message_id or something like that
I know this is a lot to ask but the TLDR is
With a react frontend, how should I go about serving images from AWS securely and easily (I'm a relatively new developer) Maybe this is the wrong place to ask, but if someone could give me some tips, advice, experience or leads or resources or things to research or ANYTHING that would be so much appreciated!