docker
docker copied to clipboard
DJANGO_DEBUG == True means no static files are downloaded
I'm installing wger on my home server and wanted to use HTTPS. As per the docs, I preemptively set DJANGO_DEBUG=True just in case I had issues. Then promptly spent 3 hours debugging why the static folder wasn't being populated. I'm using mapped volumes, but permissions seemed alright. Until I found out this in the entrypoint.sh:
if [[ "$DJANGO_DEBUG" == "False" ]];
then
echo "Running in production mode, running collectstatic now"
python3 manage.py collectstatic --no-input $clear
fi
I would like to leave a suggestion here to note this potential issue in the README. I'm also leaving this here in case anyone else stumbles upon this issue.