diff --git a/charts/argo-cd/Chart.yaml b/charts/argo-cd/Chart.yaml index 04a5fb87..dcd05a27 100644 --- a/charts/argo-cd/Chart.yaml +++ b/charts/argo-cd/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v1 appVersion: "1.4.2" description: A Helm chart for ArgoCD, a declarative, GitOps continuous delivery tool for Kubernetes. name: argo-cd -version: 1.8.7 +version: 1.8.8 home: https://github.com/argoproj/argo-helm icon: https://raw.githubusercontent.com/argoproj/argo/master/docs/assets/argo.png keywords: diff --git a/charts/argo-cd/README.md b/charts/argo-cd/README.md index e9a022f4..91c415d9 100644 --- a/charts/argo-cd/README.md +++ b/charts/argo-cd/README.md @@ -257,3 +257,5 @@ Helm v3 has removed the `install-crds` hook so CRDs are now populated by files i | redis.resources | Resource limits and requests for redis | `{}` | | redis.servicePort | Redis service port | `6379` | | redis.tolerations | Tolerations for use with node taints https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ | `[]` | +| redis.ha | Configures Redis HA subchart https://github.com/helm/charts/tree/master/stable/redis-ha | | | +| redis.ha.enabled | Enables the Redis HA subchart and disabled the custom Redis single node deployment| `false` | diff --git a/charts/argo-cd/charts/redis-ha-4.3.4.tgz b/charts/argo-cd/charts/redis-ha-4.3.4.tgz new file mode 100644 index 00000000..2ada79ee Binary files /dev/null and b/charts/argo-cd/charts/redis-ha-4.3.4.tgz differ diff --git a/charts/argo-cd/requirements.lock b/charts/argo-cd/requirements.lock new file mode 100644 index 00000000..17f99d57 --- /dev/null +++ b/charts/argo-cd/requirements.lock @@ -0,0 +1,6 @@ +dependencies: +- name: redis-ha + repository: https://kubernetes-charts.storage.googleapis.com + version: 4.3.4 +digest: sha256:281b2ee97e4ae47d8248912db4207bbb19f098de8de037452f7b50ebcc2819d4 +generated: "2020-03-18T20:14:33.015349017Z" diff --git a/charts/argo-cd/requirements.yaml b/charts/argo-cd/requirements.yaml index e69de29b..4ef0adaf 100644 --- a/charts/argo-cd/requirements.yaml +++ b/charts/argo-cd/requirements.yaml @@ -0,0 +1,6 @@ +dependencies: +- name: redis-ha + alias: redis.ha + version: 4.3.4 + repository: https://kubernetes-charts.storage.googleapis.com + condition: redis.ha.enabled \ No newline at end of file diff --git a/charts/argo-cd/templates/_helpers.tpl b/charts/argo-cd/templates/_helpers.tpl index af7f7c9f..64a68f8d 100644 --- a/charts/argo-cd/templates/_helpers.tpl +++ b/charts/argo-cd/templates/_helpers.tpl @@ -42,8 +42,12 @@ Create dex name and version as used by the chart label. Create redis name and version as used by the chart label. */}} {{- define "argo-cd.redis.fullname" -}} +{{- if .Values.redis.ha.enabled -}} +{{- printf "%s-redis-ha-haproxy" .Release.Name | trunc 63 | trimSuffix "-" -}} +{{- else -}} {{- printf "%s-%s" (include "argo-cd.fullname" .) .Values.redis.name | trunc 63 | trimSuffix "-" -}} {{- end -}} +{{- end -}} {{/* Create argocd server name and version as used by the chart label. diff --git a/charts/argo-cd/templates/redis/deployment.yaml b/charts/argo-cd/templates/redis/deployment.yaml index 60896660..e6538875 100755 --- a/charts/argo-cd/templates/redis/deployment.yaml +++ b/charts/argo-cd/templates/redis/deployment.yaml @@ -1,4 +1,4 @@ -{{- if .Values.redis.enabled }} +{{- if and .Values.redis.enabled (not .Values.redis.ha.enabled) }} apiVersion: apps/v1 kind: Deployment metadata: diff --git a/charts/argo-cd/templates/redis/service.yaml b/charts/argo-cd/templates/redis/service.yaml index a30d5986..5f0bb1e4 100644 --- a/charts/argo-cd/templates/redis/service.yaml +++ b/charts/argo-cd/templates/redis/service.yaml @@ -1,4 +1,4 @@ -{{- if .Values.redis.enabled }} +{{- if and .Values.redis.enabled (not .Values.redis.ha.enabled) }} apiVersion: v1 kind: Service metadata: diff --git a/charts/argo-cd/values.yaml b/charts/argo-cd/values.yaml index cef83273..4a311bb4 100755 --- a/charts/argo-cd/values.yaml +++ b/charts/argo-cd/values.yaml @@ -282,6 +282,24 @@ redis: volumeMounts: [] volumes: [] + # This key configures Redis-HA subchart and when enabled (redis.ha.enabled=true) + # the custom redis deployment is omitted + ha: + enabled: false + # Check the redis-ha chart for more properties + exporter: + enabled: true + persistentVolume: + enabled: false + redis: + masterGroupName: argocd + config: + save: "\"\"" + haproxy: + enabled: true + metrics: + enabled: true + ## Server server: name: server