File tree Expand file tree Collapse file tree 2 files changed +9
-17
lines changed
Expand file tree Collapse file tree 2 files changed +9
-17
lines changed Original file line number Diff line number Diff line change @@ -82,7 +82,6 @@ Use [the awesome `gossm` project](https://github.com/gjbae1212/gossm).
8282
8383| Name | Source | Version |
8484| ------| --------| ---------|
85- | <a name =" module_asg_label " ></a > [ asg\_ label] ( #module\_ asg\_ label ) | cloudposse/label/null | 0.25.0 |
8685| <a name =" module_kms_key " ></a > [ kms\_ key] ( #module\_ kms\_ key ) | cloudposse/kms-key/aws | 0.12.1 |
8786| <a name =" module_logs_bucket " ></a > [ logs\_ bucket] ( #module\_ logs\_ bucket ) | cloudposse/s3-bucket/aws | 3.1.2 |
8887| <a name =" module_logs_label " ></a > [ logs\_ label] ( #module\_ logs\_ label ) | cloudposse/label/null | 0.25.0 |
Original file line number Diff line number Diff line change 1- module "asg_label" {
2- source = " cloudposse/label/null"
3- version = " 0.25.0"
4-
5- context = module. this . context
6-
7- # This tag attribute is required.
8- # See https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/autoscaling_group#propagate_at_launch
9- additional_tag_map = {
10- propagate_at_launch = " true"
11- }
12- }
13-
141module "role_label" {
152 source = " cloudposse/label/null"
163 version = " 0.25.0"
@@ -331,9 +318,15 @@ resource "aws_launch_template" "default" {
331318}
332319
333320resource "aws_autoscaling_group" "default" {
334- name_prefix = " ${ module . asg_label . id } -asg"
335- tags = module. asg_label . tags_as_list_of_maps
336-
321+ name_prefix = " ${ module . this . id } -asg"
322+ dynamic "tag" {
323+ for_each = module. this . tags
324+ content {
325+ key = tag. key
326+ value = tag. value
327+ propagate_at_launch = true
328+ }
329+ }
337330 launch_template {
338331 id = aws_launch_template. default . id
339332 version = " $Latest"
You can’t perform that action at this time.
0 commit comments