mirror of
https://github.com/2martens/terraform.git
synced 2026-10-17 22:06:51 +02:00
Use older version of Argo CD
This commit is contained in:
@@ -213,6 +213,7 @@ resource "hcloud_server" "server_k8s_test" {
|
||||
argocd_ha_values : base64encode(file("${path.module}/modules/k8s-cluster/templates/helm/argocd-values-ha.yaml"))
|
||||
cluster_setup : base64encode(templatefile("${path.module}/modules/k8s-cluster/templates/scripts/cluster-setup.sh", {
|
||||
argocd_environment : "test"
|
||||
argocd_version : "5.34.3"
|
||||
high_availability : false
|
||||
}))
|
||||
})
|
||||
|
||||
@@ -115,6 +115,7 @@ resource "hcloud_server" "manager" {
|
||||
argocd_ha_values : base64encode(file("${path.module}/templates/helm/argocd-values-ha.yaml"))
|
||||
cluster_setup : base64encode(templatefile("${path.module}/templates/scripts/cluster-setup.sh", {
|
||||
argocd_environment : var.argocd_environment
|
||||
argocd_version : var.argocd_chart_version
|
||||
high_availability : var.number_nodes > 2
|
||||
}))
|
||||
})
|
||||
|
||||
@@ -7,7 +7,7 @@ done
|
||||
/snap/bin/microk8s.helm3 repo add 2martens https://repo.2martens.de/charts/
|
||||
/snap/bin/microk8s.helm3 install setup 2martens/cluster_setup --values /run/tmpfiles.d/cluster-setup-values.yaml
|
||||
%{ if high_availability ~}
|
||||
/snap/bin/microk8s.helm3 install argo-cd 2martens/argocd --create-namespace -n argocd --set environment=${argocd_environment} --values /run/tmpfiles.d/argocd-values-ha.yaml
|
||||
/snap/bin/microk8s.helm3 install argo-cd 2martens/argocd --create-namespace -n argocd --version ${argocd_version} --set environment=${argocd_environment} --values /run/tmpfiles.d/argocd-values-ha.yaml
|
||||
%{ else ~}
|
||||
/snap/bin/microk8s.helm3 install argo-cd 2martens/argocd --create-namespace -n argocd --set environment=${argocd_environment}
|
||||
/snap/bin/microk8s.helm3 install argo-cd 2martens/argocd --create-namespace -n argocd --version ${argocd_version} --set environment=${argocd_environment}
|
||||
%{ endif ~}
|
||||
@@ -86,6 +86,12 @@ variable "argocd_environment" {
|
||||
default = "test"
|
||||
}
|
||||
|
||||
variable "argocd_chart_version" {
|
||||
description = "The Argo CD chart version to use."
|
||||
type = string
|
||||
default = "5.34.3"
|
||||
}
|
||||
|
||||
variable "number_nodes" {
|
||||
description = "Number of manager nodes in the cluster."
|
||||
type = number
|
||||
|
||||
@@ -94,6 +94,7 @@ resource "hcloud_server" "worker" {
|
||||
argocd_ha_values : base64encode(file("${path.module}/templates/helm/argocd-values-ha.yaml"))
|
||||
cluster_setup : base64encode(templatefile("${path.module}/templates/scripts/cluster-setup.sh", {
|
||||
argocd_environment : var.argocd_environment
|
||||
argocd_version : var.argocd_chart_version
|
||||
high_availability : var.number_nodes > 2
|
||||
}))
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user