awscli question:

0

I created a user in IAM identity center. Then I opened a terminal, and then use aws sso login to get the login session successfully. But when I ran aws ec2 describe-regions command in the same terminal, I got the error below: aws ec2 describe-regions

An error occurred (ForbiddenException) when calling the GetRoleCredentials operation: No access

My IAM identity center user has already been granted AdministratorAccess permission.

Any idea on the solution to fix this issue?

Thanks,

已提问 1 个月前286 查看次数
1 回答
1

It may be linked to the configuration settings in your AWS environment. To ensure the correct setup, use the following command with your AWS CLI, specifying your SSO profile. This will help verify that your SSO profile is correctly configured and has the necessary permissions:

aws ec2 describe-regions --profile your-profile-name

💡 I suspect that the SSO configuration isn't properly set up in your terminal.


Try to configure your AWS environement:

  1. Configure the SSO Profile: aws configure sso --profile your-profile-name
  2. Login Using SSO: aws sso login --profile your-profile-name
  3. Try previous command: aws ec2 describe-regions --profile your-profile-name
profile picture
专家
已回答 1 个月前
profile picture
专家
已审核 1 个月前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则