Demo: Attaching a Read-Only Policy to an EC2 Instance

Learn how to create an S3 read-only policy and attach it to an EC2 instance.

Let’s see how to deploy an application using AWS CodeDeploy. The diagram below shows that the EC2 instance needs an IAM role to read contents from S3 buckets. So, before deploying the application, let’s create this role using AWS CLI and assign it to our EC2 instance.

Get hands-on with 1400+ tech skills courses.