From d511b0ca77bd3a90e8ed28b19f6a845a703f413d Mon Sep 17 00:00:00 2001 From: charlesmmarshall Date: Thu, 16 Feb 2023 12:55:52 +0000 Subject: [PATCH] known issue (https://github.com/integrations/terraform-provider-github/issues/1147), trying this workaround before changing the provider version --- github_repository.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/github_repository.tf b/github_repository.tf index 32d6037..ae324c1 100644 --- a/github_repository.tf +++ b/github_repository.tf @@ -67,7 +67,7 @@ resource "github_branch_protection_v3" "repository_main" { enforce_admins = var.enforce_admins required_status_checks { - strict = var.require_ci_pass + strict = length(var.status_checks) > 0 ? var.require_ci_pass: null contexts = length(var.status_checks) > 0 ? var.status_checks : null }