Section 7: AWS CLI, SDK, IAM Roles & Policies Flashcards
What can you use to develop and perform AWS tasks from your local computer?
The CLI
The SDK
What can you use to develop and perform AWS tasks from an EC2 instance?
The CLI
The SDK
The Instance Metadata Service for EC2
How to configure the AWS CLI (default profile) on your local computer?
aws configure
How to configure the AWS CLI (a specific profile) on your local computer?
aws configure โprofile profileName
What info do you have to provide when configuring the AWS CLI on your computer?
Access Key ID
Secret Access Key
Default Region Name
Default output format (leave to none by default)
Where are the config/credentials files stored on Windows?
In the User/.aws folder
How to configure the AWS CLI on an EC2 instance?
By assigning an AWS IAM role to the machine (or the ASG which will assign the role to the machine it creates)
Can you do โaws configureโ on an EC2 machine?
YOU SHOULD NEVER DO THAT! Your PERSONAL credentials should belongs on your PERSONAL compter
How to define what actions an IAM Role can perform?
By assigning policies to the IAM Role
How many roles can an EC2 instance have?
Only one
What are inline policies?
Policies that are creatable โinlineโ inside a role. Those inline policies wonโt be findable in the policies tab and wonโt be attachable to other roles
Should you use inline policies?
Itโs better to avoid using inline policies, just to facilitate their management
What visual tools can you use to generate policies? (2)
The visual editor integrated in โcreate policyโ page
The AWS Policy Generator
Is it possible to see what roles use a policy from the console, if so, how?
Yes, by looking at the โPolicy usageโ tab
Can custom IAM policies have versions?
Yes, you can view them in the โPolicy versionโ tab of a policy