We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents ace2bc9 + 65b4f5e commit 738b82cCopy full SHA for 738b82c
iam.tf
@@ -129,11 +129,10 @@ resource "aws_iam_policy" "network" {
129
policy = data.aws_iam_policy_document.network[0].json
130
}
131
132
-resource "aws_iam_policy_attachment" "network" {
+resource "aws_iam_role_policy_attachment" "network" {
133
count = var.vpc_config == null ? 0 : 1
134
135
- name = "${var.function_name}-network"
136
- roles = [aws_iam_role.lambda.name]
+ role = aws_iam_role.lambda.name
137
policy_arn = aws_iam_policy.network[0].arn
138
139
0 commit comments