Skip to content

Commit 8968e29

Browse files
Merge pull request #113 from kobim/feat/readiness-check
chore: support the extended readiness check
2 parents 15e70a6 + bcab837 commit 8968e29

File tree

5 files changed

+12
-5
lines changed

5 files changed

+12
-5
lines changed

helm/oauth2-proxy/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: oauth2-proxy
2-
version: 6.7.1
2+
version: 6.7.2
33
apiVersion: v2
44
appVersion: 7.4.0
55
home: https://oauth2-proxy.github.io/oauth2-proxy/

helm/oauth2-proxy/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ Parameter | Description | Default
150150
`priorityClassName` | priorityClassName | `nil`
151151
`readinessProbe.enabled` | enable Kubernetes readinessProbe. Disable to use oauth2-proxy with Istio mTLS. See [Istio FAQ](https://istio.io/help/faq/security/#k8s-health-checks) | `true`
152152
`readinessProbe.initialDelaySeconds` | number of seconds | 0
153-
`readinessProbe.timeoutSeconds` | number of seconds | 1
153+
`readinessProbe.timeoutSeconds` | number of seconds | 5
154154
`readinessProbe.periodSeconds` | number of seconds | 10
155155
`readinessProbe.successThreshold` | number of successes | 1
156156
`replicaCount` | desired number of pods | `1`

helm/oauth2-proxy/templates/_helpers.tpl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,3 +101,10 @@ Compute the redis url if not set explicitly.
101101
{{ fail "please set sessionStorage.redis.standalone.connectionUrl or enable the redis subchart via redis.enabled" }}
102102
{{- end -}}
103103
{{- end -}}
104+
105+
{{/*
106+
Returns the version
107+
*/}}
108+
{{- define "oauth2-proxy.version" -}}
109+
{{ trimPrefix "v" (lower (.Values.image.tag | default (printf "v%s" .Chart.AppVersion))) }}
110+
{{- end -}}

helm/oauth2-proxy/templates/deployment.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ spec:
5555
{{- end }}
5656
containers:
5757
- name: {{ .Chart.Name }}
58-
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default (printf "v%s" .Chart.AppVersion) }}"
58+
image: "{{ .Values.image.repository }}:v{{ include "oauth2-proxy.version" . }}"
5959
imagePullPolicy: {{ .Values.image.pullPolicy }}
6060
args:
6161
{{- if .Values.alphaConfig.enabled }}
@@ -194,7 +194,7 @@ spec:
194194
{{- if .Values.readinessProbe.enabled }}
195195
readinessProbe:
196196
httpGet:
197-
path: /ping
197+
path: {{ if gt (include "oauth2-proxy.version" .) "7.4.0" }}/ready{{ else }}/ping{{ end }}
198198
port: {{ .Values.httpScheme }}
199199
scheme: {{ .Values.httpScheme | upper }}
200200
initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }}

helm/oauth2-proxy/values.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ livenessProbe:
211211
readinessProbe:
212212
enabled: true
213213
initialDelaySeconds: 0
214-
timeoutSeconds: 1
214+
timeoutSeconds: 5
215215
periodSeconds: 10
216216
successThreshold: 1
217217

0 commit comments

Comments
 (0)