Monday, May 30, 2016

AWs basics: S3

Local Setup

  • npm install aws-sdk
  • create a .aws/credentails file in the ${user_home} directory ( True for both MAC, LInux and Windows )
  • Copy the below contents to the ${user_home}/.aws/credentials file:
AWSAccessKeyId=agahaha
AWSSecretKey=ahahahae

Also create .aws/config file and add the following two lines:
[default]
region = us-west-2
How to work with pre-signed URLs
Bucket name: my.test
Region: us-west-2
Content Folder: mycontent
I have tested the above by creating pre-signed URLs for upload content:
My logs:

Public and Private Folder for Content on S3

  1. Log into the AWS console
  2. Browse to my.test/content/public folder
  3. Right click and choose 'public'.
  4. Well that makes it all public.
Set CORS at AWS


No comments:

Post a Comment