Skip to content

Commit 2e96de1

Browse files
add propoagte_tags option to cloudwatch event target configuration (#11)
Co-authored-by: Robert Nesbit <[email protected]>
1 parent d7f64e3 commit 2e96de1

File tree

4 files changed

+12
-2
lines changed

4 files changed

+12
-2
lines changed

.terraform.lock.hcl

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ In order to run all checks at any point run the following command:
5454

5555
| Name | Version |
5656
|------|---------|
57-
| <a name="provider_aws"></a> [aws](#provider\_aws) | n/a |
57+
| <a name="provider_aws"></a> [aws](#provider\_aws) | 3.50.0 |
5858

5959
## Modules
6060

@@ -88,6 +88,7 @@ No modules.
8888
| <a name="input_event_target_ecs_target_assign_public_ip"></a> [event\_target\_ecs\_target\_assign\_public\_ip](#input\_event\_target\_ecs\_target\_assign\_public\_ip) | (Optional) Assign a public IP address to the ENI. Default false. | `bool` | `false` | no |
8989
| <a name="input_event_target_ecs_target_group"></a> [event\_target\_ecs\_target\_group](#input\_event\_target\_ecs\_target\_group) | (Optional) Specifies an ECS task group for the task. The maximum length is 255 characters. | `any` | `null` | no |
9090
| <a name="input_event_target_ecs_target_platform_version"></a> [event\_target\_ecs\_target\_platform\_version](#input\_event\_target\_ecs\_target\_platform\_version) | (Optional) Specifies the platform version for the task. Specify only the numeric portion of the platform version, such as 1.1.0. For more information about valid platform versions, see AWS Fargate Platform Versions. Default to LATEST | `string` | `"LATEST"` | no |
91+
| <a name="input_event_target_ecs_target_propagate_tags"></a> [event\_target\_ecs\_target\_propagate\_tags](#input\_event\_target\_ecs\_target\_propagate\_tags) | (Optional) Specifies whether to propagate the tags from the task definition to the task. If no value is specified, the tags are not propagated. | `bool` | `false` | no |
9192
| <a name="input_event_target_ecs_target_security_groups"></a> [event\_target\_ecs\_target\_security\_groups](#input\_event\_target\_ecs\_target\_security\_groups) | (Optional) The security groups associated with the task or service. If you do not specify a security group, the default security group for the VPC is used. | `list(any)` | `null` | no |
9293
| <a name="input_event_target_ecs_target_subnets"></a> [event\_target\_ecs\_target\_subnets](#input\_event\_target\_ecs\_target\_subnets) | The subnets associated with the task or service. | `list(any)` | n/a | yes |
9394
| <a name="input_event_target_ecs_target_task_count"></a> [event\_target\_ecs\_target\_task\_count](#input\_event\_target\_ecs\_target\_task\_count) | (Optional) The number of tasks to create based on the TaskDefinition. The default is 1. | `number` | `1` | no |

main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ resource "aws_cloudwatch_event_target" "ecs_scheduled_task" {
6969
platform_version = var.event_target_ecs_target_platform_version
7070
task_count = var.event_target_ecs_target_task_count
7171
task_definition_arn = var.event_target_ecs_target_task_definition_arn
72+
propagate_tags = var.event_target_ecs_target_propagate_tags
7273

7374
network_configuration {
7475
subnets = var.event_target_ecs_target_subnets

variables.tf

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,4 +109,10 @@ variable "event_target_ecs_target_assign_public_ip" {
109109
description = "(Optional) Assign a public IP address to the ENI. Default false."
110110
type = bool
111111
default = false
112-
}
112+
}
113+
114+
variable "event_target_ecs_target_propagate_tags" {
115+
description = "(Optional) Specifies whether to propagate the tags from the task definition to the task. If no value is specified, the tags are not propagated."
116+
type = bool
117+
default = false
118+
}

0 commit comments

Comments
 (0)