Heroku not running collectstatic with Django

Jad S

So I have a Django app, I've turned off DISABLE_COLLECTSTATIC but there's no mention of collect static happening.

Some research showed that Heroku would fail silently if collect static fails, but would write out during the build log when collect static succeeds. I did heroku run python manage.py collectstatic and it ran correctly. No errors.

However, collect static still isn't running on build

Jad S

The catch turned out to be that to disable a config var, one must use: heroku config:unset DISABLE_COLLECTSTATIC

I was using the wrong command since heroku config displayed initally DISABLE_COLLECTSTATIC: 1 I assumed heroku config:set DISABLE_COLLECTSTATIC=0 would turn off the config var. Since nothing else seemed off, this assumption became the next likely suspect. Following Heroku docs about handling config, I ran all of heroku config:set DISABLE_COLLECTSTATIC=false heroku config:set DISABLE_COLLECTSTATIC=False which don't work as desired.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

Error with collectstatic while deploying Django app to Heroku

Django Heroku Collectstatic error only on deploy

`collectstatic` error when deploying Django app to heroku

Error deploying on Heroku - Django app - collectstatic --noinput

Where to run collectstatic when deploying django app to heroku using docker?

Getting Permission denied when Running collectstatic in Django in ElasticBeanstalk

Permission denied on mkdir inside of a django Docker container when running collectstatic

Django - Can I delete apps static files after running collectstatic

Running Django's collectstatic in Dockerfile produces empty directory

Running collectstatic from Heroku runs successfully, but fails to push the files to AWS, run locally it's successful

Django Amazon S3 Heroku. Connection reset by peer. Remove confirmation on collectstatic script

python manage.py collectstatic --noinput error when deploying Django project to Heroku

UnicodeDecodeError Django Error Collectstatic

Django collectstatic no such file or directory

Django and Collectstatic Issue

Running collectstatic command from Dockerfile

How to make dokku run a predeploy script before running django's collectstatic?

Django installed but throws import error in virtual env when running: sudo python manage.py collectstatic

Long running file generation on Heroku + Django

Celery jobs not running on heroku (python/django app)

Heroku web dyno running Django app not releasing memory

Running through an environmental error during deploying django app on heroku

Can Django collectstatic overwrite old files?

What's the point of Django's collectstatic?

Django collectstatic not pushing to AWS S3

django collectstatic picking files from wrong location

Problems debugging Django `collectstatic` in a cloudControl deployment

django's collectstatic collects into unexpected directory

Django-admin collectstatic is an unknown command