feat(argo-cd): Add username support for external redis (#1478)

Signed-off-by: Petr Drastil <petr.drastil@gmail.com>
Signed-off-by: Eugene Lugovtsov <34510252+EugeneLugovtsov@users.noreply.github.com>

Co-authored-by: Eugene Lugovtsov <34510252+EugeneLugovtsov@users.noreply.github.com>
This commit is contained in:
Petr Drastil 2022-09-21 20:21:12 +02:00 committed by GitHub
parent e9dddd8289
commit 67659d4db0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 12 additions and 6 deletions

View file

@ -2,7 +2,7 @@ apiVersion: v2
appVersion: v2.4.12 appVersion: v2.4.12
description: A Helm chart for Argo CD, a declarative, GitOps continuous delivery tool for Kubernetes. description: A Helm chart for Argo CD, a declarative, GitOps continuous delivery tool for Kubernetes.
name: argo-cd name: argo-cd
version: 5.5.0 version: 5.5.1
home: https://github.com/argoproj/argo-helm home: https://github.com/argoproj/argo-helm
icon: https://argo-cd.readthedocs.io/en/stable/assets/logo.png icon: https://argo-cd.readthedocs.io/en/stable/assets/logo.png
keywords: keywords:
@ -19,6 +19,4 @@ dependencies:
condition: redis-ha.enabled condition: redis-ha.enabled
annotations: annotations:
artifacthub.io/changes: | artifacthub.io/changes: |
- "[Added]: New configuration section `configs.params` for command line parameters" - "[Added]: REDIS_USERNAME environment variable added automatically based on externalRedis.username"
- "[Deprecated]: Command line arguments in `args` sections"
- "[Deprecated]: Options `logFormat` and `logLevel` for core components"

View file

@ -852,6 +852,7 @@ If you want to use an existing Redis (eg. a managed service from a cloud provide
| externalRedis.password | string | `""` | External Redis password | | externalRedis.password | string | `""` | External Redis password |
| externalRedis.port | int | `6379` | External Redis server port | | externalRedis.port | int | `6379` | External Redis server port |
| externalRedis.secretAnnotations | object | `{}` | External Redis Secret annotations | | externalRedis.secretAnnotations | object | `{}` | External Redis Secret annotations |
| externalRedis.username | string | `""` | External Redis username |
## ApplicationSet ## ApplicationSet

View file

@ -1,4 +1,4 @@
{{- if and .Values.externalRedis.password (not .Values.externalRedis.existingSecret) }} {{- if and (or .Values.externalRedis.username .Values.externalRedis.password) (not .Values.externalRedis.existingSecret) }}
apiVersion: v1 apiVersion: v1
kind: Secret kind: Secret
metadata: metadata:
@ -13,5 +13,10 @@ metadata:
{{- end }} {{- end }}
type: Opaque type: Opaque
data: data:
redis-password: {{ .Values.externalRedis.password | b64enc }} {{- with .Values.externalRedis.username }}
redis-username: {{ . | b64enc }}
{{- end }}
{{- with .Values.externalRedis.password }}
redis-password: {{ . | b64enc }}
{{- end }}
{{- end }} {{- end }}

View file

@ -1089,6 +1089,8 @@ redis-ha:
externalRedis: externalRedis:
# -- External Redis server host # -- External Redis server host
host: "" host: ""
# -- External Redis username
username: ""
# -- External Redis password # -- External Redis password
password: "" password: ""
# -- External Redis server port # -- External Redis server port