So on the left hand side of IAM,
there are roles
and you may see zero roles.
Right now I have six,
it's because I use a different kind of account.
So don't worry about it.
Okay. It doesn't matter for this hands on, but we have roles
and roles allow entities in the AWS to get credentials
for a short duration and to do whatever they need to do.
So let's go ahead
and create our first role and we'll have the same thing.
So we are going to choose a trusted entity type.
And as we can see, we have different types.
So we can create roles for either services, if you will.
There are also accounts with identities, SAML Federation
custom trust policy.
All of these are out of scope for the exam.
The only thing we need to know
even for the hands on is just
that we can create role for AWS services and amongst them
the two most common use cases is to create a role
for an EC2 instance or for Lambda function.
But as you can see, you go here.
There are lots of AWS services
that can support having roles, okay.
And the roles are everywhere in AWS.
But to keep it simple right now
we are going to create a role,
an IAM role for the EC2 instances.
So let's click on next.
Okay. Next I'm going to have to assign policies
and permissions to that role.
So we will allow that role to do
IAM read only access.
This is going to allow my EC2 instance to read
from IAM.
We click on next?
And then we have to define a role name.
Okay. So you choose whatever you want for role name
for example, I will enter demo role for EC2.
And then we verify that, yes
we did have the IAM read only access
and we create this role.
So the role has now been created.
And if I click on it
we can verify that the permissions are applied correctly,
the IAM read only access.
And we are not going to use this role right now.
We will stop right here.
But when we get to the EC2 section of this course
we will be leveraging this role
allowing the EC2 instance to perform actions
against IAM and read data from IAM okay.
So that's it for this lecture.
I hope you liked it.
And I will see you in the next lecture.