2回答
- 新しい順
- 投票が多い順
- コメントが多い順
3
This should do it
resource "aws_iam_role" "role_identifier" {
name = var.role_name
assume_role_policy = jsonencode({
Version = "2012-10-17"
Statement = [
{
Action = "sts:AssumeRole"
Effect = "Allow"
Sid = ""
Principal = {
Service = "ec2.amazonaws.com"
}
},
]
})
}
0
Hi,
Your policy contains two statements. The first part has Principal but the second part only has the following:
{ Action = "AssumeRole", Effect = "Allow" }
This second part needs to be cleaned up as it looks like it is not required.
回答済み 7ヶ月前
関連するコンテンツ
- AWS公式更新しました 1年前
- AWS公式更新しました 1年前