File tree Expand file tree Collapse file tree 4 files changed +5
-22
lines changed Expand file tree Collapse file tree 4 files changed +5
-22
lines changed Original file line number Diff line number Diff line change @@ -49,9 +49,7 @@ data "aws_iam_policy_document" "lambda" {
49
49
" ec2:ModifyLaunchTemplate" ,
50
50
]
51
51
52
- resources = [
53
- data . aws_launch_template . template . arn ,
54
- ]
52
+ resources = var. launch_templates_arns
55
53
}
56
54
57
55
statement {
Original file line number Diff line number Diff line change @@ -5,7 +5,3 @@ data "aws_region" "current" {}
5
5
data "aws_autoscaling_group" "group" {
6
6
name = var. autoscaling_group_name
7
7
}
8
-
9
- data "aws_launch_template" "template" {
10
- name = var. launch_template_name
11
- }
Original file line number Diff line number Diff line change 1
1
output "asg_arn" {
2
2
value = data. aws_autoscaling_group . group . arn
3
3
}
4
-
5
- output "lt_arn" {
6
- value = data. aws_launch_template . template . arn
7
- }
8
-
9
- output "lt_id" {
10
- value = data. aws_launch_template . template . id
11
- }
12
-
13
- output "lt_name" {
14
- value = data. aws_launch_template . template . name
15
- }
Original file line number Diff line number Diff line change @@ -99,9 +99,10 @@ variable "lambda_timeout" {
99
99
type = number
100
100
}
101
101
102
- variable "launch_template_name" {
103
- description = " Name of the launch template used by auto scaling group to refresh"
104
- type = string
102
+ variable "launch_templates_arns" {
103
+ description = " List of Launch Template ARNs to allow access to"
104
+ default = [" *" ]
105
+ type = list (string )
105
106
}
106
107
107
108
variable "launch_template_source_version" {
You can’t perform that action at this time.
0 commit comments