Could be your uploaded file/bucket's visibility isn't set to public..
AWS Image Display Permissions Issue
Hello all,
I'm noticing a strange occurrence with displaying AWS Images directly from using the AWS URL.
In one section of my site, I have the ability to upload a logo, but this logo, once uploaded, will not display. HOWEVER, I have another section of the site that generates a PDF using the "barryvdh/laravel-dompdf" package. In this PDF that's generated, the image displays properly.
The code is the same on both pages:
<img src="https://awsbucketaddress.amazonaws.com/{{ Auth::user()->company->company_logo->filepath }}">
I think this is because I blacklist all IP addresses to the AWS Images in the AWS Bucket. Then I whitelist the IP Address of my production server. Is it possible that this dompdf package pulls the image in using the production server's IP address, then displays it to the page, but when I display the logo on the other page, it doesn't pull it from the server--rather, it pulls it from the user's IP address?
Is it possible to force the image to be accessed via the server's IP address rather than the user's IP address? Or will I need to download the image temporarily to the server, then server the local image? Looking for options on this. I'd prefer to keep the images ONLY stored in the AWS Bucket, rather than having to download to the production server.
Let me know if there's more information required. Thanks in advance.
Please or to participate in this conversation.