Skip to content

Commit

Permalink
Merge branch 'main' into an/27aug/cloud-map-namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewnguonly committed Aug 27, 2024
2 parents 06650cf + 250fcff commit 0fbe6e8
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions modules/langgraph_cloud_setup/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,10 @@ resource "aws_iam_role" "langgraph_cloud_role" {
}

// Attach the necessary policies to the role
resource "aws_iam_policy_attachment" "role_attachments" {
resource "aws_iam_role_policy_attachment" "role_attachments" {
for_each = toset(["AmazonVPCReadOnlyAccess", "AmazonECS_FullAccess", "SecretsManagerReadWrite", "CloudWatchReadOnlyAccess", "AmazonRDSFullAccess"])
name = "LangGraphCloudRoleAttachment-${each.key}"
policy_arn = "arn:aws:iam::aws:policy/${each.key}"
roles = [aws_iam_role.langgraph_cloud_role.name]
role = aws_iam_role.langgraph_cloud_role.name
}

resource "aws_iam_policy" "custom_permissions" {
Expand All @@ -58,10 +57,9 @@ resource "aws_iam_policy" "custom_permissions" {
})
}

resource "aws_iam_policy_attachment" "custom_policy" {
name = "LangGraphCloudRoleAttachment-CustomPermissions"
resource "aws_iam_role_policy_attachment" "custom_policy" {
policy_arn = aws_iam_policy.custom_permissions.arn
roles = [aws_iam_role.langgraph_cloud_role.name]
role = aws_iam_role.langgraph_cloud_role.name
}


Expand Down

0 comments on commit 0fbe6e8

Please sign in to comment.