Recipes v0.8.1 Release Notes
Release Date: 2020-06-03 // almost 4 years ago-
- ๐ fixes not being redirected to setup page on first launch
- ๐ fixes media serving with DEBUG=False
Media serving important information
TLDR; If you don't use nginx (or any other webserver) in your docker setup (
docker-compose.yml
) please update it to include one (see this and this example). Lastly addGUNICORN_MEDIA=0
to your.env
file๐ If you want to continue serving media files without a webserver (which is not recommended, see explanaition) add
GUNICORN_MEDIA=1
to your.env
file and everything should work as before.Explanation:
๐ In PR #39 and subsequent commits we introduced Whitenoise as the static file server for everything included in the static files directories. Doing this seemingly allowed us to get rid of the additional nginx container running to serve static/media files. By changing the default debug mode to false (which it should have been a long time) in the 0.8.0 release media file serving broke, as they were always served trough debug features.๐ Basically everyone recommends not doing this, even tough it appear to be more a performance and less a security issue. To allow you to continue using the gunicorn to serve media files the
GUNICORN_MEDIA
setting was added to the.env
file.The recommended solution is to add back the nginx container into your
docker-compose.yml
. To do so simply add the container as shown in this and this example. You also need to download thenxinx
folder and place it next to yourdocker-compose.yml
. If you need any help migrating feel free to raise an issue and ask for it.๐ For the next few releases
GUNICORN_MEDIA
will default to true in order not to break existing installation on updates, some kind of warning will be displayed with the next version.