inputlogic / django-api-starter

Boilerplate for starting Django DRF / API projects
2 stars 0 forks source link

Make heroku bucketeer work without needing aws cli commands #147

Open adriaanwm opened 1 year ago

adriaanwm commented 1 year ago

Currently need to run something like this in order for collectstatic and s3 in general to work on heroku:

aws configure

aws s3api put-public-access-block --bucket <BUCKET_NAME> --public-access-block-configuration BlockPublicAcls=FALSE,IgnorePublicAcls=FALSE,BlockPublicPolicy=FALSE,RestrictPublicBuckets=FALSE

aws s3api put-bucket-ownership-controls \
    --bucket <BUCKET_NAME> \
    --ownership-controls="Rules=[{ObjectOwnership=BucketOwnerPreferred}]"

More info here: https://devcenter.heroku.com/articles/bucketeer