Skip to content

Commit

Permalink
fix dimension error and fix count set error
Browse files Browse the repository at this point in the history
  • Loading branch information
mbbilgen committed Aug 9, 2023
1 parent 63a1ddc commit b27a6d7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions apps/lambda_function_scheduled/lambda.tf
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ resource "aws_lambda_function" "app" {
resource "aws_lambda_permission" "cloudwatch" {
statement_id = "AllowExecutionFromCloudWatch"
action = "lambda:InvokeFunction"
function_name = "${aws_lambda_function.app.arn}"
function_name = "${aws_lambda_function.app[0].arn}"
principal = "events.amazonaws.com"
source_arn = "${aws_cloudwatch_event_rule.app.arn}"
source_arn = "${aws_cloudwatch_event_rule.app[0].arn}"
count = "${var.enabled}"
}

Expand Down
2 changes: 1 addition & 1 deletion apps/lambda_function_scheduled/outputs.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
output "lambda_arn" {
value = "${aws_lambda_function.app.arn}"
value = "${aws_lambda_function.app[0].arn}"
}
output "iam_role_arn" {
value = "${aws_iam_role.iam_for_app.arn}"
Expand Down

0 comments on commit b27a6d7

Please sign in to comment.