How to change an IAM role session duration?

Cloud Computing

Hi Guys,

I have created an IAM role in AWS. Now I want to change an IAM role session duration from the command line. How can I do that?

1
Answers

Replies

Ans:Yes, it is possible to change an IAM role session duration. The update-role command will help in changing the description of the IAM role production role to the Main production role . The mazimum session duration is set up to 12 hours. Below is the representation of the update-role.


$ aws iam update-role --role-name production-role --description 'Main production role' --max-session-duration 43200

 
 

If you want to unleash your potential in this competitive field, please visit the Cloud Computing course page for more information, where you can find the Cloud Computing tutorials and Cloud Computing frequently asked interview questions and answers as well.

 

This topic has been locked/unapproved. No replies allowed

Login to participate in this discussion.

Leave a reply

Before proceeding, please check your email for a verification link. If you did not receive the email, click here to request another.