Enable to upload images on prod / Nordflank

default discord avatar
andrew_a
2 weeks ago
1

Hi there!



Locally, I am able to use media without problems.



import path from 'path'; import type { CollectionConfig } from 'payload/types'; const Media: CollectionConfig = { slug: 'media', upload: { staticURL: '/uploads', staticDir: '../uploads', // Specify the size name that you'd like to use as admin thumbnail adminThumbnail: 'thumbnail', imageSizes: [ { height: 400, width: 400, crop: 'center', name: 'thumbnail', }, { width: 900, height: 450, crop: 'center', name: 'sixteenByNineMedium', }, ], }, fields: [], }; export default Media;

However, when I try to upload a file on prod deployed on Nordflank, I guess the following error:



You are not allowed to perform this action.



Fixed by reading:

https://northflank.com/guides/deploying-payload-cms#common-issues
    Open the post
    Continue the discussion in Discord
    Like what we're doing?
    Star us on GitHub!

    Star

    Connect with the Payload Community on Discord

    Discord

    online

    Can't find what you're looking for?

    Get help straight from the Payload team with an Enterprise License.