Bootstrap FreeKB - Amazon Web Services (AWS) - Attach a Role to an IAM Profiles using the AWS CLI
Amazon Web Services (AWS) - Attach a Role to an IAM Profiles using the AWS CLI


This assumes you have already configured the aws command line tool. If not, check out my article on Getting Started with the AWS CLI.

The aws iam create-instance-profile command can be used to create a new profile. In this example, a profile named my-profile will be created.

aws iam create-instance-profile --instance-profile-name my-profile

 

And then the aws iam add-role-to-instance-profile command to attach a role to the profile.

aws iam add-role-to-instance-profile --role-name my-role --instance-profile-name my-profile

 




Did you find this article helpful?

If so, consider buying me a coffee over at Buy Me A Coffee



Comments


Add a Comment


Please enter fc4e44 in the box below so that we can be sure you are a human.