From 81ac0669c04d5de3d487824ecef87420c3ecef3b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julian=20T=C3=B6lle?= Date: Wed, 2 Feb 2022 19:27:25 +0100 Subject: [PATCH] fix: github_repo branches get created every apply --- k3s_cluster_v2/flux.tf | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/k3s_cluster_v2/flux.tf b/k3s_cluster_v2/flux.tf index cfc0a65..dbd8885 100644 --- a/k3s_cluster_v2/flux.tf +++ b/k3s_cluster_v2/flux.tf @@ -110,6 +110,14 @@ resource "github_repository" "main" { name = var.repository_name visibility = var.repository_visibility auto_init = true + + lifecycle { + ignore_changes = [ + # Ignored until this issue is resolved: + # https://github.com/integrations/terraform-provider-github/issues/1037 + branches, + ] + } } resource "github_branch_default" "main" {