DEV Community

Vicente G. Reyes
Vicente G. Reyes

Posted on

Static Files not saving on S3 bucket using cookiecutter-django

I'm trying to deploy this app since last night. Tried to re-deploy it but it still doesn't save the static files on the s3 bucket.

I'm trying to deploy my project on Heroku. I ran heroku run python3 manage.py collectstatic after deploying it.

I have this on config/base.py

STATIC_ROOT = str(ROOT_DIR("staticfiles"))
STATIC_URL = "/static/"
STATICFILES_DIRS = [str(APPS_DIR.path("static"))]
STATICFILES_FINDERS = [
    "django.contrib.staticfiles.finders.FileSystemFinder",
    "django.contrib.staticfiles.finders.AppDirectoriesFinder",
]

This is on the config/production.py

BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
INSTALLED_APPS += ["storages"]  #

Latest comments (0)