Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove deprecate is_enabled variable. Use state instead #33

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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