Heroku + S3 = img's with expiry #4669
Replies: 4 comments 1 reply
-
Yeah, this is one of the most common issues people run into that gets reported in the Solidus Slack #support channel. The backend isn't an issue because there's no caching. The frontend runs into the issue that much of the product show and listing pages are cached, so when the expiring URLs are generated, they get reused beyond the lifespan of the generated image URLs. |
Beta Was this translation helpful? Give feedback.
-
So what is the recommendation here because im running out of ideas haha @jarednorman |
Beta Was this translation helpful? Give feedback.
-
If you set the bucket policy to make all objects in the bucket public, that'll solve it. |
Beta Was this translation helpful? Give feedback.
-
Are there any alternatives to setting For example, I do not want images and other media attached to my applications ActionText RichText fields to also be public, and
So far the only sure fire thing I've thought of is to split my app into two parts and serve them up seperately, but that's very messy, a whole lot of work, and I would absolutely like to avoid it possible... |
Beta Was this translation helpful? Give feedback.
-
There is no clear documentation around how to properly setup the s3 bucket and the solidus instance on heroku so img's dont expire.... Whats strange is the img's dont expire on the solidus backend panel, its only on the customer facing front end views
Solidus Version:
3.1.7
To Reproduce
deploy to heroku with s3 config, upload an img, visit the customer facing ui, wait 5 min and the img will expire and will not display
Current behavior
the img link is expiring on the frontend and its a bit confusing why
Expected behavior
Im expecting for the url to the img to refresh or reload or something
Screenshots
Desktop (please complete the following information):
Beta Was this translation helpful? Give feedback.
All reactions