Cloudinary upload fails and I see a CORS error

System Information
  • Strapi Version: 4.9.0
  • Operating System: Ubuntu 22.04
  • Database: Postgres
  • Node Version: v16.19.0
  • NPM Version: 8.19.3
  • Yarn Version: 1.22.19

When I try to upload an image to Cloudinary, It fails. I see a console error at the same time.

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at (Reason: CORS request did not succeed). Status code: (null).

The error is related to This seems unrelated to the Cloudinary upload so I’m rather confused. Is this analytics failing and causing the image upload to fail? Is there a way to disable it?

Unfortunately, I see no errors in my Dokku logs, so this is difficult to troubleshoot.

Edit: just found strapi/ at dd227e2b645901ff35aa8d599ecfe8bae27850ab · strapi/strapi · GitHub I will try and report back

1 Like

Realized client-max-body-size was not set in my nginx config. I set it to 50m and it fixed my Cloudinary uploads.

I was suspicious about the analytics setting so I tried deploying with and without analytics enabled. It had no effect on the uploads either way.