#Media too large

6 messages · Page 1 of 1 (latest)

fringe crane
#

Hi again!

I've been having trouble uploading files in production (DO Droplet). I get an error "Your request was too large to submit successfully".

The file is a 1.4M image,

I have this in my `payload.config.js``

{
upload: {
    limits: {
      fileSize: 5000000,
    },
  },
  express: {
    json: {
      limit: 5000000,
    },
  },
}

Could this be more of a Droplet problem?

charred agate
#

Are you using a reverse proxy with nginx ? If so the upload limit is 1mb

fringe crane
#

Yep, I'm using a reverse proxy, thanks a lot!!!

charred agate
#

Your then after client_max_body_size 🙂

fringe crane
#

Kinda tricky to find where to change/add client_max_body_size but i find it! Thanks again!

charred agate
#

You are using nginx ?