Skip to content

Commit

Permalink
add iam role app_task
Browse files Browse the repository at this point in the history
  • Loading branch information
roncitrus committed Feb 2, 2024
1 parent 234fac7 commit 2ebb6eb
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions terraform/environments/cdpt-ifs/ecs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,30 @@ resource "aws_ecs_cluster" "ecs_cluster" {
}
}

resource "aws_iam_role" "app_task" {
name = "task-${var.networking[0].application}"

assume_role_policy = <<EOF
{
"Version": "2012-10-17",
"Statement": [
{
"Action": "sts:AssumeRole",
"Principal": {
"Service": "ecs-tasks.amazonaws.com"
},
"Effect": "Allow",
"Sid": ""
}
]
}
EOF

tags = merge(
local.tags,
{
Name = "task-${var.networking[0].application}"
},
)
}

0 comments on commit 2ebb6eb

Please sign in to comment.