From 9277f2d1cb28015083476c1e3274f43ffc5dfc02 Mon Sep 17 00:00:00 2001 From: Whitney Date: Fri, 3 Feb 2023 12:17:26 +0000 Subject: [PATCH] update scan frequency validation with signed commit --- variables.tf | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/variables.tf b/variables.tf index 52b8d90..e559531 100644 --- a/variables.tf +++ b/variables.tf @@ -97,6 +97,15 @@ variable "scan_frequency_hours" { type = number description = "How often in hours the scan will run in hours. Defaults to `24`." default = 24 + + validation { + condition = ( + var.scan_frequency_hours == 24 || + var.scan_frequency_hours == 12 || + var.scan_frequency_hours == 6 + ) + error_message = "The scan frequency must be 6, 12, or 24 hours." + } } variable "agentless_scan_secret_id" {