diff --git a/main.tf b/main.tf index 3a4a16b..a36c9d5 100644 --- a/main.tf +++ b/main.tf @@ -129,15 +129,17 @@ resource "github_repository_ruleset" "default" { bypass_mode = "always" } + conditions { + ref_name { + exclude = [] + include = ["refs/tags/${var.tag_protection}"] + } + } + rules { creation = true update = true deletion = true - - tag_name_pattern { - operator = "regex" - pattern = var.tag_protection - } } }