I’m creating a role to reboot automatically an EC2 instance. But I’m getting this error "The execution role you provide must allow AWS EventBridge Scheduler to assume the role."
In the role, I’ve added those permissions
I know it’s mostly too much but still not enough cause I’m getting the error… Any idea ?
2
Answers
Since the error message indicates EventBridge Scheduler is unable to assume the role, you are probably missing the IAM piece that allows the "sts:AssumeRole" action. This doc for IAM describes where you need to add these permissions.
You need to add the below trust policy to your execution role which will allow EventBridge Scheduler to assume the role.
Open IAM Console → In the navigation pane of the console, choose Roles and then choose your role → Select Trust Relationship tab → Click on Edit trust Policy and add the below policy.