Skip to content

Commit

Permalink
Remove deprecate is_enabled variable. Use state instead (#33)
Browse files Browse the repository at this point in the history
  • Loading branch information
jnonino authored Mar 17, 2024
1 parent b0a5ec2 commit 5038115
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ resource "aws_cloudwatch_event_rule" "event_rule" {
event_pattern = var.event_rule_event_pattern
description = var.event_rule_description
role_arn = var.event_rule_role_arn == null ? aws_iam_role.scheduled_task_cw_event_role[0].arn : var.event_rule_role_arn
is_enabled = var.event_rule_is_enabled
state = var.event_rule_state
tags = {
Name = "${var.name_prefix}-cw-event-rule"
}
Expand Down
8 changes: 4 additions & 4 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ variable "event_rule_role_arn" {
type = string
}

variable "event_rule_is_enabled" {
description = "(Optional) Whether the rule should be enabled (defaults to true)."
default = true
type = bool
variable "event_rule_state" {
description = "(Optional) State of the rule. Valid values are DISABLED, ENABLED, and ENABLED_WITH_ALL_CLOUDTRAIL_MANAGEMENT_EVENTS. When state is ENABLED, the rule is enabled for all events except those delivered by CloudTrail. To also enable the rule for events delivered by CloudTrail, set state to ENABLED_WITH_ALL_CLOUDTRAIL_MANAGEMENT_EVENTS. Defaults to ENABLED."
default = "ENABLED"
type = string
}

#------------------------------------------------------------------------------
Expand Down

0 comments on commit 5038115

Please sign in to comment.