Skip to content

Commit 9b08b04

Browse files
authored
feat: switch to dandydeveloper/redis-ha chart 🚀 (#335)
* feat: switch to dandydeveloper/redis-ha chart Signed-off-by: Jan Larwig <[email protected]> * fix the test cases Signed-off-by: Jan Larwig <[email protected]> * doc: update readme Signed-off-by: Jan Larwig <[email protected]> --------- Signed-off-by: Jan Larwig <[email protected]>
1 parent 1454687 commit 9b08b04

File tree

11 files changed

+159
-67
lines changed

11 files changed

+159
-67
lines changed

.github/workflows/release.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
2525
- name: Add Helm repositories
2626
run: |
27-
helm repo add bitnami https://charts.bitnami.com/bitnami
27+
helm repo add dandydev https://dandydeveloper.github.io/charts
2828
2929
- name: Run chart-releaser
3030
uses: helm/[email protected]

ct.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ chart-dirs:
55
target-branch: main
66
# helm-extra-args: --timeout 600s
77
chart-repos:
8-
- bitnami=https://charts.bitnami.com/bitnami
8+
- dandydev=https://dandydeveloper.github.io/charts

helm/oauth2-proxy/Chart.lock

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
dependencies:
2-
- name: redis
3-
repository: https://charts.bitnami.com/bitnami
4-
version: 22.0.1
5-
digest: sha256:7e8f393290629839ef212fb63e9ab4c5170ccba3da30c06c464a554987fcbb45
6-
generated: "2025-08-11T14:45:37.460990457Z"
2+
- name: redis-ha
3+
repository: https://dandydeveloper.github.io/charts
4+
version: 4.33.8
5+
digest: sha256:99abe093ebc97b930cad234e3bce566bb55e11ed0b2324e195d9783aaf5d1ace
6+
generated: "2025-08-13T08:08:37.645426006+02:00"

helm/oauth2-proxy/Chart.yaml

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: oauth2-proxy
2-
version: 7.18.0
2+
version: 8.0.0
33
apiVersion: v2
44
appVersion: 7.11.0
55
home: https://oauth2-proxy.github.io/oauth2-proxy/
@@ -13,9 +13,9 @@ keywords:
1313
- github
1414
- redis
1515
dependencies:
16-
- name: redis
17-
version: 22.0.1
18-
repository: https://charts.bitnami.com/bitnami
16+
- name: redis-ha
17+
version: 4.33.8
18+
repository: https://dandydeveloper.github.io/charts
1919
alias: redis
2020
condition: redis.enabled
2121
sources:
@@ -31,10 +31,8 @@ maintainers:
3131
kubeVersion: ">=1.16.0-0"
3232
annotations:
3333
artifacthub.io/changes: |
34-
- kind: added
35-
description: Added support for PodDisruptionBudget unhealthyPodEvictionPolicy
34+
- kind: changed
35+
description: Replace Redis chart by bitnami with dandydeveloper/redis-ha chart
3636
links:
3737
- name: Github PR
38-
url: https://github.com/oauth2-proxy/manifests/pull/336
39-
- name: Kubernetes documentation
40-
url: https://kubernetes.io/docs/tasks/run-application/configure-pdb/#unhealthy-pod-eviction-policy
38+
url: https://github.com/oauth2-proxy/manifests/pull/335

helm/oauth2-proxy/README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,13 @@ Version 7.0.0 introduces a new implementation to support multiple hostAliases.
9494
You probably need to adjust your hostAliases config.
9595
See [here](https://github.com/oauth2-proxy/manifests/pull/164/) for detailed information.
9696

97+
### To 8.0.0 - Bitnami 💀
98+
99+
Version 8.0.0 removes the dependency on the Bitnami Redis subchart and replaces it with the `dandydeveloper/redis-ha` chart. Therefore this version introduces a breaking change to the redis subchart deployment configuration. Please refer to the official [redis-ha repository](https://github.com/DandyDeveloper/charts/tree/master/charts/redis-ha) for details. Furthermore, you can reference the redis CI test value files we use [here](https://github.com/oauth2-proxy/manifests/tree/main/helm/oauth2-proxy/ci).
100+
101+
Furthermore, you can read up on why this change was necessary in [Breaking changes in Bitnami Catalog #323](https://github.com/oauth2-proxy/manifests/issues/323)
102+
103+
97104
## Configuration
98105

99106
The following table lists the configurable parameters of the oauth2-proxy chart and their default values.

helm/oauth2-proxy/ci/redis-sentinel-array-values.yaml

Lines changed: 20 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,29 @@ sessionStorage:
66
password: "foo"
77
masterName: "mymaster"
88
connectionUrls:
9-
- "redis://oauth2-proxy-redis:26379"
10-
- "redis://oauth2-proxy-redis:26379"
9+
- "redis://oauth2-proxy-redis-announce-0:26379"
10+
- "redis://oauth2-proxy-redis-announce-1:26379"
11+
12+
# provision an instance of the redis-ha sub-chart
1113
redis:
12-
# provision an instance of the redis sub-chart
1314
enabled: true
1415
fullnameOverride: oauth2-proxy-redis
15-
architecture: replication
16-
sentinel:
17-
enabled: true
18-
masterSet: mymaster
19-
global:
20-
redis:
21-
password: "foo"
16+
17+
redisPassword: "foo"
18+
19+
redis:
20+
masterGroupName: mymaster
21+
22+
replicas: 2
23+
hardAntiAffinity: false
24+
25+
persistentVolume:
26+
enabled: false
27+
haproxy:
28+
enabled: false
29+
exporter:
30+
enabled: false
31+
2232
initContainers:
2333
waitForRedis:
2434
enabled: true

helm/oauth2-proxy/ci/redis-sentinel-comma-values.yaml

Lines changed: 19 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,28 @@ sessionStorage:
55
sentinel:
66
password: "foo"
77
masterName: "mymaster"
8-
connectionUrls: "redis://oauth2-proxy-redis:26379,redis://oauth2-proxy-redis:26379"
8+
connectionUrls: "redis://oauth2-proxy-redis-announce-0:26379,redis://oauth2-proxy-redis-announce-1:26379"
9+
10+
# provision an instance of the redis-ha sub-chart
911
redis:
10-
# provision an instance of the redis sub-chart
1112
enabled: true
1213
fullnameOverride: oauth2-proxy-redis
13-
architecture: replication
14-
sentinel:
15-
enabled: true
16-
masterSet: mymaster
17-
global:
18-
redis:
19-
password: "foo"
14+
15+
redisPassword: "foo"
16+
17+
redis:
18+
masterGroupName: mymaster
19+
20+
replicas: 2
21+
hardAntiAffinity: false
22+
23+
persistentVolume:
24+
enabled: false
25+
haproxy:
26+
enabled: false
27+
exporter:
28+
enabled: false
29+
2030
initContainers:
2131
waitForRedis:
2232
enabled: true

helm/oauth2-proxy/ci/redis-standalone-values.yaml

Lines changed: 56 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,64 @@ sessionStorage:
33
redis:
44
clientType: "standalone"
55
password: "foo"
6+
7+
# provision an instance of the redis-ha sub-chart
68
redis:
7-
# provision an instance of the redis sub-chart
89
enabled: true
9-
architecture: standalone
10-
global:
11-
redis:
12-
password: "foo"
10+
fullnameOverride: oauth2-proxy-redis
11+
12+
redisPassword: "foo"
13+
14+
replicas: 1
15+
16+
# Remove sentinel overhead, speed up startup and redis itself
17+
sentinel:
18+
livenessProbe:
19+
enabled: false
20+
readinessProbe:
21+
enabled: false
22+
startupProbe:
23+
enabled: false
24+
quorum: 1
25+
26+
hardAntiAffinity: false
27+
28+
redis:
29+
config:
30+
min-replicas-to-write: 0
31+
save: ""
32+
appendonly: "no"
33+
34+
terminationGracePeriodSeconds: 10
35+
livenessProbe:
36+
initialDelaySeconds: 5
37+
periodSeconds: 5
38+
timeoutSeconds: 3
39+
failureThreshold: 2
40+
readinessProbe:
41+
initialDelaySeconds: 5
42+
periodSeconds: 5
43+
timeoutSeconds: 3
44+
failureThreshold: 2
45+
startupProbe:
46+
initialDelaySeconds: 5
47+
periodSeconds: 2
48+
timeoutSeconds: 3
49+
failureThreshold: 10
50+
splitBrainDetection:
51+
interval: 0
52+
persistentVolume:
53+
enabled: false
54+
emptyDir: {}
55+
haproxy:
56+
enabled: false
57+
exporter:
58+
enabled: false
59+
sysctlImage:
60+
enabled: false
61+
hostPath:
62+
chown: false
63+
1364
initContainers:
1465
waitForRedis:
1566
enabled: true

helm/oauth2-proxy/templates/_helpers.tpl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ Redis subcharts fullname
9494
*/}}
9595
{{- define "oauth2-proxy.redis.fullname" -}}
9696
{{- if .Values.redis.enabled -}}
97-
{{- include "common.names.fullname" (dict "Chart" (dict "Name" "redis") "Release" .Release "Values" .Values.redis) -}}
97+
{{- include "redis-ha.fullname" (dict "Chart" (dict "Name" "redis-ha") "Release" .Release "Values" .Values.redis) -}}
9898
{{- else -}}
9999
{{ fail "attempting to use redis subcharts fullname, even though the subchart is not enabled. This will lead to misconfiguration" }}
100100
{{- end -}}
@@ -107,7 +107,7 @@ Compute the redis url if not set explicitly.
107107
{{- if .Values.sessionStorage.redis.standalone.connectionUrl -}}
108108
{{ .Values.sessionStorage.redis.standalone.connectionUrl }}
109109
{{- else if .Values.redis.enabled -}}
110-
{{- printf "redis://%s-master:%.0f" (include "oauth2-proxy.redis.fullname" .) .Values.redis.master.service.ports.redis -}}
110+
{{- printf "redis://%s:%.0f" (include "oauth2-proxy.redis.fullname" .) .Values.redis.redis.port -}}
111111
{{- else -}}
112112
{{ fail "please set sessionStorage.redis.standalone.connectionUrl or enable the redis subchart via redis.enabled" }}
113113
{{- end -}}

helm/oauth2-proxy/templates/deployment.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ spec:
199199
{{- if eq (default "cookie" .Values.sessionStorage.type) "redis" }}
200200
- name: OAUTH2_PROXY_SESSION_STORE_TYPE
201201
value: "redis"
202-
{{- if or .Values.sessionStorage.redis.existingSecret .Values.sessionStorage.redis.password (and .Values.redis.enabled (.Values.redis.auth).enabled )}}
202+
{{- if or .Values.sessionStorage.redis.existingSecret .Values.sessionStorage.redis.password (and .Values.redis.enabled (.Values.redis.auth))}}
203203
- name: OAUTH2_PROXY_REDIS_PASSWORD
204204
valueFrom:
205205
secretKeyRef:

0 commit comments

Comments
 (0)