How to access bucket subfolders?
betancourtl opened this issue · comments
Luis commented
How can I set the location of the static files? I've done this before when using django-storages
but I'm not sure how it works with this package.
This is how I have been able to set this up using django-storages
class MediaStorage(S3Boto3Storage):
bucket_name = 'my-app-bucket'
location = 'media'
class StaticStorage(S3Boto3Storage):
bucket_name = 'my-app-bucket'
location = 'static'
Dave Hall commented
The AWS_S3_KEY_PREFIX setting (suffixed with _STATIC if necessary), is what
you want.
…On Fri, 22 May 2020 at 16:01, Luis ***@***.***> wrote:
How can I set the location of the static files? I've done this before when
using django-storages but I'm not sure how it works with this package.
class MediaStorage(S3Boto3Storage):
bucket_name = 'my-app-bucket'
location = 'media'
class StaticStorage(S3Boto3Storage):
bucket_name = 'my-app-bucket'
location = 'static'
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#109>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABEKCBVK464A27I4VLVKKLRS2HVHANCNFSM4NH3M5RA>
.