Created
July 12, 2016 18:52
-
-
Save bjinwright/990da644f3b3ea74e700801b15914adf to your computer and use it in GitHub Desktop.
Django Storages S3 custom folder based on settings
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from django.conf import settings | |
from storages.backends.s3boto import S3BotoStorage | |
class StaticStorage(S3BotoStorage): | |
location = settings.STATICFILES_LOCATION | |
class MediaStorage(S3BotoStorage): | |
location = settings.MEDIAFILES_LOCATION |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment