From 14d1abddd514808689b3f9eef817000ffc42028a Mon Sep 17 00:00:00 2001 From: Alexey Zhokhov Date: Sun, 15 Nov 2026 02:14:26 +0700 Subject: [PATCH] Record that pull_request_creation_policy is applied outside Terraform Co-Authored-By: Claude Sonnet 5.5 Signed-off-by: Alexey Zhokhov --- modules/repository-policy/main.tf | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/modules/repository-policy/main.tf b/modules/repository-policy/main.tf index fd8aa2d..db575da 100644 --- a/modules/repository-policy/main.tf +++ b/modules/repository-policy/main.tf @@ -36,6 +36,10 @@ resource "github_repository" "managed_settings" { allow_update_branch = false delete_branch_on_merge = true + # TODO: pull_request_creation_policy = "collaborators_only" is set on every repository through the REST API + # until the provider supports it: https://github.com/integrations/terraform-provider-github/pull/3479 + # Then add it here and widen the provider constraint in versions.tf and this module. + lifecycle { prevent_destroy = true ignore_changes = [