MEDIA_ROOT = BASE_DIR / 'media' is not valid Python so I'm not even sure how your app can be running.
I think the setting you want is probably more like this:
MEDIA_ROOT = BASE_DIR + '/media/'
If that doesn't work then try using the full path instead of a computed path, eg:
MEDIA_ROOT = '/home/user/apps/appname/path/to/media/'
I also recommend that you use a static symlink app to serve media files, instead of serving them directly from Django. This will make your app faster and will reduce its memory usage. If you want to do that:
- Create a new Nginx static symlink app at https://my.opalstack.com/apps/ pointing to '/home/user/apps/appname/path/to/media/'
- Route that app to your site at https://my.opalstack.com/domains/ with /media as the URI path.