Skip to content

Commit

Permalink
Allow empty string var.hieradata
Browse files Browse the repository at this point in the history
Simplify things with MC-Hub
  • Loading branch information
cmd-ntrf committed Sep 20, 2024
1 parent 886f2bf commit 8e6aee9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion common/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ variable "hieradata" {
default = "---"
description = "String formatted as YAML defining hiera key-value pairs to be included in the puppet environment"
validation {
condition = can(yamldecode(var.hieradata))
condition = var.hieradata == "" || can(yamldecode(var.hieradata))
error_message = "Hieradata needs to be valid YAML"
}
}
Expand Down

0 comments on commit 8e6aee9

Please sign in to comment.