From 265f78321a2e945ec2d032050a5653ec6c5e81cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gon=C3=A7alo=20Heleno?= Date: Fri, 12 Jan 2024 15:48:55 +0100 Subject: [PATCH] fix!: remove the namespace variable We found out that on multiple modules we were referencing resources from other modules using their default namespaces and this was hardcoded. In case someone decided to change the namespace of deployment of a certain application, this could break the way modules work with each other. We've decided that in order to avoid undefined behaviors caused by overloading this variable, it would be best to remove it entirely. --- main.tf | 4 ++-- variables.tf | 6 ------ 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/main.tf b/main.tf index 834a352..ba07b4c 100644 --- a/main.tf +++ b/main.tf @@ -19,7 +19,7 @@ resource "argocd_project" "this" { destination { name = var.destination_cluster - namespace = var.namespace + namespace = "longhorn-system" } orphaned_resources { @@ -68,7 +68,7 @@ resource "argocd_application" "this" { destination { name = var.destination_cluster - namespace = var.namespace + namespace = "longhorn-system" } sync_policy { diff --git a/variables.tf b/variables.tf index 4dc17ff..7aec653 100644 --- a/variables.tf +++ b/variables.tf @@ -50,12 +50,6 @@ variable "target_revision" { default = "v2.3.0" # x-release-please-version } -variable "namespace" { - description = "Namespace where the applications's Kubernetes resources should be created. Namespace will be created in case it doesn't exist." - type = string - default = "longhorn-system" -} - variable "helm_values" { description = "Helm chart value overrides. They should be passed as a list of HCL structures." type = any