Provision of S3 bucket with IAM user permission

I am assuming that you have created a new bucket or are using an existing bucket, and have also given access permission to this bucket and your IAM user. You must give the following permission through the S3 bucket policy, to upload files to any directory in the Amazon S3 bucket with the AWS account number, 123412341234:

{ 
    "Statement": [ 
        { 
            "Action": [ 
                "s3:PutObject" 
            ], 
            "Effect": "Allow", 
            "Resource": "arn:aws:s3:::codedeploydemoapp/*", 
            "Principal": { 
                "AWS": [ 
                    "123412341234" 
                ] 
            } 
        } 
    ] 
} 

You must also attach the following policy to the S3 bucket policy to allow download requests from each Amazon EC2 instance:

{ "Statement": [ { "Action": [ "s3:Get*", "s3:List*" ], "Effect": "Allow", "Resource": ...

Get Expert AWS Development now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.