File tree Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -37,14 +37,22 @@ resource "aws_iam_role" "this" {
3737data "aws_iam_policy_document" "lambda_policy_doc" {
3838 statement {
3939 actions = [
40- " autoscaling:SetInstanceHealth" ,
41- " autoscaling:DescribeAutoScalingGroups"
40+ " autoscaling:SetInstanceHealth"
4241 ]
4342
4443 resources = [
4544 " arn:aws:autoscaling:${ local . region } :${ local . account_id } :*:autoScalingGroupName/${ var . asg_name } "
4645 ]
4746 }
47+ statement {
48+ actions = [
49+ " autoscaling:DescribeAutoScalingGroups"
50+ ]
51+
52+ resources = [
53+ " *"
54+ ]
55+ }
4856}
4957
5058resource "aws_iam_role_policy" "this" {
@@ -72,8 +80,8 @@ resource "aws_lambda_function" "this" {
7280 tags = module. tags . tags
7381 environment {
7482 variables = {
75- ASG_NAME = var.asg_name
76- LOGLEVEL = var.loglevel
83+ ASG_NAME = var.asg_name
84+ LOGLEVEL = var.loglevel
7785 }
7886 }
7987 lifecycle {
You can’t perform that action at this time.
0 commit comments