generated from plus3it/repo-template
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathvariables.tf
43 lines (36 loc) · 1.24 KB
/
variables.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
variable "event_rule" {
description = "Object of input configs for the CloudWatch Event Rule"
type = object({
name = string
description = optional(string)
event_pattern = optional(string)
event_bus_name = optional(string, "default")
schedule_expression = optional(string)
state = optional(string)
event_targets = optional(list(object({
name = string
arn = string
event_bus_name = optional(string, "default")
role_arn = optional(string)
target_id = optional(string)
dead_letter_config = optional(object({
arn = string
}))
input_transformer = optional(object({
input_paths = optional(map(string))
input_template = string
}))
sqs_target = optional(object({
message_group_id = string
}))
retry_policy = optional(object({
maximum_event_age_in_seconds = optional(string)
maximum_retry_attempts = optional(string)
}))
})), [])
})
validation {
condition = var.event_rule.schedule_expression == null || var.event_rule.event_bus_name == "default"
error_message = "Scheduled expressions cannot be used on custom event buses"
}
}