diff --git a/changelog.d/20240412_140658_andres.md b/changelog.d/20240412_140658_andres.md new file mode 100644 index 0000000..9306f56 --- /dev/null +++ b/changelog.d/20240412_140658_andres.md @@ -0,0 +1 @@ +- [Bugfix] Fix the docker image to allow media files to be served by uwsgi. (by @angonz) \ No newline at end of file diff --git a/tutordiscovery/templates/discovery/build/discovery/Dockerfile b/tutordiscovery/templates/discovery/build/discovery/Dockerfile index dbc66e8..d983f11 100644 --- a/tutordiscovery/templates/discovery/build/discovery/Dockerfile +++ b/tutordiscovery/templates/discovery/build/discovery/Dockerfile @@ -73,6 +73,9 @@ RUN python manage.py compilemessages COPY --chown=app:app assets.py ./course_discovery/settings/assets.py RUN DJANGO_SETTINGS_MODULE=course_discovery.settings.assets make static +# Create media directory to serve media files +RUN mkdir course_discovery/media + # Run production server ENV DJANGO_SETTINGS_MODULE course_discovery.settings.tutor.production EXPOSE 8000