amplify-hosting icon indicating copy to clipboard operation
amplify-hosting copied to clipboard

"Unable to assume IAM Role" but really issue is repo is private

Open schwigri opened this issue 8 months ago • 3 comments

Environment information

N/A

Describe the bug

I had made a repo private, but the Amplify GitHub app has full permissions to all the repos. However, when deploying the app I kept getting the error that it was unable to assume the IAM role during build. Only when I made the repo public again did the build succeed.

Error looks like this

2025-02-13T01:47:24.337Z [ERROR]: !!! Unable to assume specified IAM Role. Please ensure the selected IAM Role has sufficient permissions and the Trust Relationship is configured correctly.

Since error is seemingly related to IAM, I was delayed in deploying client site for over an hour with updates while trying to figure out IAM issues.

Reproduction steps

  1. Make GitHub repo private
  2. Reconnect repository and ensure the Amplify app in GitHub has permission to all repos
  3. Try to deploy the app and it will fail during build

schwigri avatar Feb 13 '25 01:02 schwigri