can't assume role from EC2 even with the policy attached
AWS CLI v2.15, instance profile attached to an EC2 box running our worker. aws sts get-caller-identity works fine and shows the instance role, but aws s3 ls on a bucket I know the role should reach gives An error occurred (AccessDenied) when calling the ListBuckets operation: Access Denied. Role has an inline policy with s3:ListBucket on the bucket ARN. Trust policy allows ec2.amazonaws.com. Reattached the profile and rebooted. What am I missing?
3 replies