0

I have a DjangoRest/ Vue.js app. I have endpoints where I upload users pictures. In production my urls were : "picture": "http://127.0.0.1:8000/media/image.jpg" Now with my app deployed on Heroku it's: "picture": "https://myapp.herokuapp.com/media/image.jpg", But as I try to GET an uploaded picture, I get a

Not Found The requested resource was not found on this server.

In my settings.py I have:

MEDIA_ROOT = os.path.join(BASE_DIR, '..', 'uploaded_media')
MEDIA_URL = '/media/'

And in my urls.py:

urlpatterrns[] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)

What am I missing?

Toto Briac
  • 908
  • 9
  • 29

0 Answers0