
getenv ( 'AWS_SECRET_ACCESS_KEY' ) AWS_STORAGE_BUCKET_NAME = os.

getenv ( 'AWS_ACCESS_KEY_ID' ) AWS_SECRET_ACCESS_KEY = os. getenv ( 'USE_S3' ) = 'TRUE' if USE_S3 : # aws settings AWS_ACCESS_KEY_ID = os.

If you'd like to limit access even more, to the specific bucket we just created, create a new policy with the following permissions: Then, click the "Create group" button, provide a name for the group and then search for and select the built-in policy "AmazonS3FullAccess":Ĭlick "Create Group" to finish setting up the group: Within the AWS Console, navigate to the main IAM page and click "User groups" on the sidebar. So, we'll start by setting up a group with limited permissions and then create a user and assign that user to the group. What's more, by setting up a group, it makes it much easier to assign (and remove) access to the bucket. You should now see your bucket back on the main S3 page:Īlthough you could use the AWS root user, it's best for security to create an IAM user that only has access to S3 or to a specific S3 bucket. Give the bucket a unique, DNS-compliant name and select a region:Ĭreate the bucket. To create an S3 bucket, navigate to the S3 page and click "Create bucket": If you’re new to AWS, Amazon provides a free tier with 5GB of S3 storage. Before beginning, you will need an AWS account.
