Skip to content

Commit

Permalink
fix!: remove the namespace variable
Browse files Browse the repository at this point in the history
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.
  • Loading branch information
lentidas committed Jan 12, 2024
1 parent e4dae7c commit 265f783
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
4 changes: 2 additions & 2 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ resource "argocd_project" "this" {

destination {
name = var.destination_cluster
namespace = var.namespace
namespace = "longhorn-system"
}

orphaned_resources {
Expand Down Expand Up @@ -68,7 +68,7 @@ resource "argocd_application" "this" {

destination {
name = var.destination_cluster
namespace = var.namespace
namespace = "longhorn-system"
}

sync_policy {
Expand Down
6 changes: 0 additions & 6 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 265f783

Please sign in to comment.