diff --git a/helm-charts/custom/oidc-client-helm/oidc-client-helm/oidc-client/values.yaml b/helm-charts/custom/oidc-client-helm/oidc-client-helm/oidc-client/values.yaml index f13fbb8..494ac53 100644 --- a/helm-charts/custom/oidc-client-helm/oidc-client-helm/oidc-client/values.yaml +++ b/helm-charts/custom/oidc-client-helm/oidc-client-helm/oidc-client/values.yaml @@ -34,6 +34,7 @@ config: listen: https://0.0.0.0:5555 redirect_uri: https://10.10.10.3:30555/callback +# Default probe configs livenessProbe: initialDelaySeconds: 1 failureThreshold: 1 diff --git a/helm-charts/upstream/dexidp-helm/debian/deb_folder/patches/0001-Added-support-to-tweak-liveness-Probe.patch b/helm-charts/upstream/dexidp-helm/debian/deb_folder/patches/0001-Added-support-to-tweak-liveness-Probe.patch new file mode 100644 index 0000000..207d908 --- /dev/null +++ b/helm-charts/upstream/dexidp-helm/debian/deb_folder/patches/0001-Added-support-to-tweak-liveness-Probe.patch @@ -0,0 +1,62 @@ +From 114850f8fb58d006292b0e2e871a235b1cf5e9c4 Mon Sep 17 00:00:00 2001 +From: Joaci Morais +Date: Fri, 16 Aug 2024 11:03:55 -0300 +Subject: [PATCH] Added support to tweak liveness Probe + +We need to adjust periodSeconds and timeoutSeconds in the +livenessProbe and readinessProbe in order to avoid heavy load +on weak cpu's + +Signed-off-by: Joaci Morais +--- + templates/deployment.yaml | 8 ++++++++ + values.yaml | 13 +++++++++++++ + 2 files changed, 21 insertions(+) + +diff --git a/templates/deployment.yaml b/templates/deployment.yaml +index 247dd39f..d976df08 100644 +--- a/templates/deployment.yaml ++++ b/templates/deployment.yaml +@@ -107,10 +107,18 @@ spec: + httpGet: + path: /healthz/live + port: telemetry ++ initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }} ++ periodSeconds: {{ .Values.livenessProbe.periodSeconds }} ++ timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }} ++ failureThreshold: {{ .Values.livenessProbe.failureThreshold }} + readinessProbe: + httpGet: + path: /healthz/ready + port: telemetry ++ initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} ++ periodSeconds: {{ .Values.readinessProbe.periodSeconds }} ++ timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} ++ failureThreshold: {{ .Values.readinessProbe.failureThreshold }} + resources: + {{- toYaml .Values.resources | nindent 12 }} + volumeMounts: +diff --git a/values.yaml b/values.yaml +index 7452791e..a3088aa3 100644 +--- a/values.yaml ++++ b/values.yaml +@@ -334,3 +334,16 @@ networkPolicy: + # ports: + # - port: 636 + # protocol: TCP ++ ++# Default probe configs ++livenessProbe: ++ initialDelaySeconds: 1 ++ failureThreshold: 3 ++ periodSeconds: 10 ++ timeoutSeconds: 1 ++ ++readinessProbe: ++ initialDelaySeconds: 1 ++ failureThreshold: 3 ++ periodSeconds: 10 ++ timeoutSeconds: 1 +\ No newline at end of file +-- +2.25.1 diff --git a/helm-charts/upstream/dexidp-helm/debian/deb_folder/patches/series b/helm-charts/upstream/dexidp-helm/debian/deb_folder/patches/series index 3018f71..841c6b0 100644 --- a/helm-charts/upstream/dexidp-helm/debian/deb_folder/patches/series +++ b/helm-charts/upstream/dexidp-helm/debian/deb_folder/patches/series @@ -1 +1,2 @@ 0001-Create-new-config-value-extraStaticClients.patch +0001-Added-support-to-tweak-liveness-Probe.patch diff --git a/stx-oidc-auth-helm/stx-oidc-auth-helm/fluxcd-manifests/dex/dex-static-overrides.yaml b/stx-oidc-auth-helm/stx-oidc-auth-helm/fluxcd-manifests/dex/dex-static-overrides.yaml index 3c66b06..8f35b1f 100644 --- a/stx-oidc-auth-helm/stx-oidc-auth-helm/fluxcd-manifests/dex/dex-static-overrides.yaml +++ b/stx-oidc-auth-helm/stx-oidc-auth-helm/fluxcd-manifests/dex/dex-static-overrides.yaml @@ -70,3 +70,15 @@ strategy: maxUnavailable: 1 maxSurge: 1 type: RollingUpdate + +livenessProbe: + failureThreshold: 3 + initialDelaySeconds: 13 + periodSeconds: 13 + timeoutSeconds: 8 + +readinessProbe: + failureThreshold: 3 + initialDelaySeconds: 13 + periodSeconds: 13 + timeoutSeconds: 8 diff --git a/stx-oidc-auth-helm/stx-oidc-auth-helm/fluxcd-manifests/oidc-client/oidc-client-static-overrides.yaml b/stx-oidc-auth-helm/stx-oidc-auth-helm/fluxcd-manifests/oidc-client/oidc-client-static-overrides.yaml index d2567a4..547382c 100644 --- a/stx-oidc-auth-helm/stx-oidc-auth-helm/fluxcd-manifests/oidc-client/oidc-client-static-overrides.yaml +++ b/stx-oidc-auth-helm/stx-oidc-auth-helm/fluxcd-manifests/oidc-client/oidc-client-static-overrides.yaml @@ -32,3 +32,15 @@ affinity: - stx-oidc-client topologyKey: kubernetes.io/hostname helmv3Compatible: true + +livenessProbe: + failureThreshold: 3 + initialDelaySeconds: 13 + periodSeconds: 13 + timeoutSeconds: 8 + +readinessProbe: + failureThreshold: 3 + initialDelaySeconds: 13 + periodSeconds: 13 + timeoutSeconds: 8