-
Notifications
You must be signed in to change notification settings - Fork 21
Description
Hello!
I've been using the default Ghost storage adapter for a while, and have got a few year's worth of images in my content/images/ folder.
Recently though I've switched to using Cloudinary for my image storage, and I've activated this adapter.
However all my old images no longer work. Let's say I'm requesting image 2022/05/Untitled.png. This is what happens:
- Ghost responds with 301 for
{domain}/content/images/2022/05/Untitled.png, redirecting to{domain}/content/images/2022/05/untitled.png. - Ghost responds with 404 for
{domain}/content/images/2022/05/untitled.png(makes sense, the image doesn't exist)
What I'm not sure about is why the original 301 response!
Deactivating this storage adapter and going back to the default one fixes the problem. No more 301s, and therefore no more 404s.
Looking through the code, I can't see anywhere in this storage adapter that would fall back to the filesystem (but also I don't know much about the code).
Should it fall back to the filesystem if the image is not found in Cloudinary? Or are we expected to migrate all our in-post images to Cloudinary before switching the adapter?
Looking at previous issues and PRs I found #90 which was closed without merging, seems like it adds this missing functionality.