You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We can use this example for variables validations:
locals {
is_sns_or_email_set = length(var.cost_anomaly_detection_subscriber_sns_topic_arns) > 0 || length(var.cost_anomaly_detection_subscriber_email_addresses) > 0
is_threshold_set = var.cost_anomaly_detection_threshold != null
should_create = var.create_cost_anomaly_detection_alert
validate_condition = local.should_create && (!local.is_sns_or_email_set || !local.is_threshold_set)
validation_message = "If create_cost_anomaly_detection_alert is set to true, either SNS or email must be set, and the threshold must be non-null."
No description provided.
The text was updated successfully, but these errors were encountered: