Skip to content

Commit

Permalink
Merge pull request #22 from Food-fusion-Fiap/add_policy_ssm
Browse files Browse the repository at this point in the history
Adiciona ARN ssm
  • Loading branch information
CAVAh authored May 12, 2024
2 parents 45ed72a + 8d30722 commit ae01578
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions data.tf
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
data "aws_caller_identity" "current" {}

data "aws_vpc" "main" {
filter {
name = "tag:Name"
Expand Down
2 changes: 1 addition & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ resource "aws_iam_policy" "ssm_policy" {
"ssm:GetParameters",
"ssm:GetParameter"
],
Resource = "/${var.project_name}/*"
Resource = "arn:aws:ssm:${var.region}:${data.aws_caller_identity.current.account_id}:parameter/${var.project_name}/*"
}
]
})
Expand Down

0 comments on commit ae01578

Please sign in to comment.