From dcd3380e623b45160415c9e9290a8e501b04b3bb Mon Sep 17 00:00:00 2001 From: Xavier Rakotomamonjy Date: Thu, 8 Sep 2022 10:01:43 +0200 Subject: [PATCH 1/2] chore: apply terraform fmt --- bootstrap/main.tf | 2 +- bootstrap/outputs.tf | 2 +- bootstrap/values.tf | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/bootstrap/main.tf b/bootstrap/main.tf index d24f8709..d1160e7f 100644 --- a/bootstrap/main.tf +++ b/bootstrap/main.tf @@ -45,7 +45,7 @@ resource "htpasswd_password" "argocd_server_admin" { } data "utils_deep_merge_yaml" "values" { - input = [for i in concat(local.helm_values, [{"argo-cd" = tomap(var.helm_values.0)}]) : yamlencode(i)] + input = [for i in concat(local.helm_values, [{ "argo-cd" = tomap(var.helm_values.0) }]) : yamlencode(i)] } resource "null_resource" "this" { diff --git a/bootstrap/outputs.tf b/bootstrap/outputs.tf index ce7b7905..981bc745 100644 --- a/bootstrap/outputs.tf +++ b/bootstrap/outputs.tf @@ -30,7 +30,7 @@ output "argocd_domain" { } output "bootstrap_values" { - value = [yamldecode(data.utils_deep_merge_yaml.values.output)] + value = [yamldecode(data.utils_deep_merge_yaml.values.output)] sensitive = true } diff --git a/bootstrap/values.tf b/bootstrap/values.tf index 7a3057dc..b942c2d1 100644 --- a/bootstrap/values.tf +++ b/bootstrap/values.tf @@ -8,8 +8,8 @@ locals { argocdServerAdminPassword = "${htpasswd_password.argocd_server_admin.bcrypt}" argocdServerAdminPasswordMtime = "2020-07-23T11:31:23Z" extra = { - "accounts.pipeline.tokens" = "${replace(local.argocd.accounts_pipeline_tokens, "\\\"", "\"")}" - "server.secretkey" = "${replace(local.argocd.server_secretkey, "\\\"", "\"")}" + "accounts.pipeline.tokens" = "${replace(local.argocd.accounts_pipeline_tokens, "\\\"", "\"")}" + "server.secretkey" = "${replace(local.argocd.server_secretkey, "\\\"", "\"")}" } } }) From 459d4a131191e724a98d29ba6222f06aec192817 Mon Sep 17 00:00:00 2001 From: Xavier Rakotomamonjy Date: Thu, 8 Sep 2022 10:02:33 +0200 Subject: [PATCH 2/2] fix: add default value for oidc sometimes we don't want to set an oidc for argocd,e.g: for hello world test A default value helps terraform to execute the module --- variables.tf | 1 + 1 file changed, 1 insertion(+) diff --git a/variables.tf b/variables.tf index b475eeb5..a63661b1 100644 --- a/variables.tf +++ b/variables.tf @@ -19,6 +19,7 @@ variable "cluster_issuer" { variable "oidc" { description = "OIDC Settings" type = any + default = null } variable "argocd" {