Then we create an S3 bucket and upload two files into the bucket.
Then we want to create access keys in order for our EC2 instance inside our VPC can have access to our S3 bucket.
In order to create access keys, we need to create an IAM user with though privileges. You can look over the follow tutorial on the below link to get you started.
Once you have created the IAM user and access keys we can go to the EC2 Connect Instance and connect to our EC2 instance with the IAM user. We will then type the command “aws s3 ls” to view the files in our s3 bucket.
Then to test if we really interact with our s3 bucket from within our EC2 instance, we make a file with the command “sudo touch /tmp/test.txt”, and then copy/move it to our s3 bucket with the command “aws s3 cp /tmp/test.txt s3://nextwork-vpc-project-mitchell”.