After merging two Discourse sites, images from the second site are not loading, despite the Upload model and files existing. pfaffman has tried various methods to resolve the issue, including manually executing code in the controller in a Rails console and using Discourse.store.list_missing_uploads(skip_optimized: true), which returned nil. RGJ suspects the 404 error might be coming from line 111 of the uploads_controller.rb file. Although pfaffman managed to fix the uploads for one post, they didn’t make detailed notes and are still seeking a solution for the remaining images.
and up.url looks like /uploads/default/original/3X/9/e/9ebb54f0e825c05df7f6df271a5cfbdc95a6332c.jpeg and cd /shared; ls uploads/default/original/3X/9/e/9ebb54f0e825c05df7f6df271a5cfbdc95a6332c.jpeg finds the file.
But https://host/uploads/default/original/3X/9/e/9ebb54f0e825c05df7f6df271a5cfbdc95a6332c.jpeg gives me a 404 from nginx.
It would seem like if the Upload exists and the file exists then NGINX would be nice and let me have it. What am I missing?
For some images, I’ve “solved” this problem by pasting in the URL of the image from the test site, which then generates the image, which then gets converted into an upload (the very same upload I just find, as far as I can tell) and then after that if I rebuild the post, it’ll have the image.
That’s how we’re the same. But I’m pretty sure you’re better at it than I am. Thanks very much for your hints.
That’s what I’m trying to do.
That seems like a good guess. Thanks!
nil. skip_optimized: false – same.
I managed to get the uploads for one post fixed, but apparently didn’t make very good notes. But I did a bunch of things to get there; I mostly have some hope that it’s possible, at least.