2 réponses
- Le plus récent
- Le plus de votes
- La plupart des commentaires
1
In short: Please don't!
Instances (systems) usually have a usage pattern that is totally different from humans. Mixing up their rights is a bound to conflict with the principle of "least privilege".
If somehow you have a use-case that requires this (please double-check!):
- Write the policy into a managed policy
- Attach it to the instance profile
- Attach it to the user (or better, their group)
répondu il y a 2 ans
1
Update the Trust Policy of the role to something like this:
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Principal": {
"Service": "ec2.amazonaws.com",
"AWS": "arn:aws:iam::0123456789012:user/johnsmith"
},
"Action": "sts:AssumeRole"
}
]
}
Thanks for your help!
Contenus pertinents
- demandé il y a un an
- demandé il y a un an
- demandé il y a un an
- demandé il y a un an
- AWS OFFICIELA mis à jour il y a 2 ans
- AWS OFFICIELA mis à jour il y a 3 mois
- AWS OFFICIELA mis à jour il y a 3 ans
Thanks for your help!