From 3f597903af55bebca225ffae6740ab3dc6ca8a6d Mon Sep 17 00:00:00 2001 From: Dori Levy Date: Thu, 10 Oct 2019 16:07:14 -0400 Subject: [PATCH 1/6] changing to thanos v0.8.0 (image repository changed); adding health + readiness probes --- thanos/Chart.yaml | 2 +- thanos/templates/query-deployment.yaml | 4 ++++ thanos/values.yaml | 4 ++-- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/thanos/Chart.yaml b/thanos/Chart.yaml index 87a2115f..9db841d6 100644 --- a/thanos/Chart.yaml +++ b/thanos/Chart.yaml @@ -9,7 +9,7 @@ keywords: sources: - https://github.com/thanos-io/thanos - https://github.com/banzaicloud/banzai-charts/tree/master/thanos -version: 0.3.5 +version: 0.3.6 icon: https://raw.githubusercontent.com/thanos-io/thanos/master/website/static/Thanos-logo_full.svg maintainers: - name: Banzai Cloud diff --git a/thanos/templates/query-deployment.yaml b/thanos/templates/query-deployment.yaml index 79be6357..8811af53 100644 --- a/thanos/templates/query-deployment.yaml +++ b/thanos/templates/query-deployment.yaml @@ -91,6 +91,10 @@ spec: httpGet: path: /-/healthy port: http + readinessProbe: + httpGet: + path: /-/ready + port: http {{- if .Values.query.certSecretName }} volumes: - name: {{ .Values.query.certSecretName }} diff --git a/thanos/values.yaml b/thanos/values.yaml index f8d2bfc7..c76a8288 100644 --- a/thanos/values.yaml +++ b/thanos/values.yaml @@ -1,6 +1,6 @@ image: - repository: improbable/thanos - tag: v0.6.0 + repository: quay.io/thanos/thanos + tag: v0.8.0 pullPolicy: IfNotPresent store: From f6cd52e46d00fe48b55a4dc5123a5dd096934f2c Mon Sep 17 00:00:00 2001 From: Dori Levy Date: Thu, 10 Oct 2019 16:07:32 -0400 Subject: [PATCH 2/6] changing to thanos v0.8.0 (image repository changed); adding health + readiness probes --- thanos/templates/store-deployment.yaml | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/thanos/templates/store-deployment.yaml b/thanos/templates/store-deployment.yaml index 37f0a9a9..d9ce5f23 100644 --- a/thanos/templates/store-deployment.yaml +++ b/thanos/templates/store-deployment.yaml @@ -23,7 +23,7 @@ spec: app.kubernetes.io/component: store template: metadata: - labels: + labels: {{ with .Values.store.labels }}{{ toYaml . | indent 8 }}{{ end }} app.kubernetes.io/name: {{ include "thanos.name" . }} app.kubernetes.io/instance: {{ .Release.Name }} @@ -84,6 +84,14 @@ spec: name: {{ .Values.store.certSecretName }} readOnly: true {{- end }} + livenessProbe: + httpGet: + path: /-/healthy + port: http + readinessProbe: + httpGet: + path: /-/ready + port: http resources: {{ toYaml .Values.store.resources | nindent 10 }} volumes: @@ -113,4 +121,4 @@ spec: {{- with .Values.store.serviceAccount }} serviceAccountName: "{{ . }}" {{- end }} -{{- end }} \ No newline at end of file +{{- end }} From 1008580e0c11201493589846cebecacdddca9d5d Mon Sep 17 00:00:00 2001 From: Dori Levy Date: Thu, 10 Oct 2019 16:18:22 -0400 Subject: [PATCH 3/6] Update readme --- thanos/README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/thanos/README.md b/thanos/README.md index 175bf8da..7a85d3c1 100644 --- a/thanos/README.md +++ b/thanos/README.md @@ -136,8 +136,8 @@ This section describes the values available ## General |Name|Description| Default Value| |----|-----------|--------------| -| image.repository | Thanos image repository and name | improbable/thanos | -| image.tag | Thanos image tag | v0.6.0 | +| image.repository | Thanos image repository and name | 'quay.io/thanos/thanos' **For Thanos version 0.6.0 or older change this to 'improbable/thanos'** | +| image.tag | Thanos image tag | v0.8.0 | | image.pullPolicy | Image Kubernetes pull policy | IfNotPresent | | objstore | Configuration for the backend object storage in yaml format. Mutually exclusive with objstoreFile. | {} | | objstoreFile | Configuration for the backend object storage in string format. Mutually exclusive with objstore. | "" | From 605c947f7539bfe95aae54b53734a5c7243be749 Mon Sep 17 00:00:00 2001 From: Dori Levy Date: Fri, 11 Oct 2019 08:29:59 -0400 Subject: [PATCH 4/6] Moving store readiness/liveness probe to optional (values) as store make take a long time to start in some cases --- thanos/README.md | 2 ++ thanos/templates/store-deployment.yaml | 12 ++++++------ thanos/values.yaml | 4 ++++ 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/thanos/README.md b/thanos/README.md index 7a85d3c1..8f34aaf3 100644 --- a/thanos/README.md +++ b/thanos/README.md @@ -194,6 +194,8 @@ These values are just samples, for more fine-tuning please check the values.yaml | store.extraEnv | Add extra environment variables | [] | | store.extraArgs | Add extra arguments | [] | | store.serviceAccount | Name of the Kubernetes service account to use | "" | +| store.livenessProbe | Set up liveness probe for store available for Thanos v0.8.0+) | {} | +| store.readinessProbe | Set up readinessProbe for store (available for Thanos v0.8.0+) | {} | ## Query diff --git a/thanos/templates/store-deployment.yaml b/thanos/templates/store-deployment.yaml index d9ce5f23..80f9760d 100644 --- a/thanos/templates/store-deployment.yaml +++ b/thanos/templates/store-deployment.yaml @@ -84,14 +84,14 @@ spec: name: {{ .Values.store.certSecretName }} readOnly: true {{- end }} + {{- if .Values.store.livenessProbe }} livenessProbe: - httpGet: - path: /-/healthy - port: http + {{ toYaml .Values.store.livenessProbe | nindent 8 }} + {{- end }} + {{- if .Values.store.readinessProbe }} readinessProbe: - httpGet: - path: /-/ready - port: http + {{ toYaml .Values.store.readinessProbe | nindent 8 }} + {{- end }} resources: {{ toYaml .Values.store.resources | nindent 10 }} volumes: diff --git a/thanos/values.yaml b/thanos/values.yaml index c76a8288..c008589c 100644 --- a/thanos/values.yaml +++ b/thanos/values.yaml @@ -134,6 +134,10 @@ store: # Ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#node-affinity affinity: {} serviceAccount: "" + # set up store readinessProbe & livenessProbe + # Ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ + livenessProbe: {} + readinessProbe: {} query: enabled: true From 6456fee2ba24e4755e4ec41091f1f32a455dfcd1 Mon Sep 17 00:00:00 2001 From: Dori Levy Date: Mon, 14 Oct 2019 10:41:48 -0400 Subject: [PATCH 5/6] Updating to v0.8.1 --- thanos/values.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/thanos/values.yaml b/thanos/values.yaml index c008589c..d70cfbdf 100644 --- a/thanos/values.yaml +++ b/thanos/values.yaml @@ -1,6 +1,6 @@ image: repository: quay.io/thanos/thanos - tag: v0.8.0 + tag: v0.8.1 pullPolicy: IfNotPresent store: From 52728b4e359bfc5cb621dcc57a62b61a9dd24392 Mon Sep 17 00:00:00 2001 From: Dori Levy Date: Mon, 14 Oct 2019 21:57:33 -0400 Subject: [PATCH 6/6] Update readme --- thanos/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/thanos/README.md b/thanos/README.md index 8f34aaf3..960e4920 100644 --- a/thanos/README.md +++ b/thanos/README.md @@ -137,7 +137,7 @@ This section describes the values available |Name|Description| Default Value| |----|-----------|--------------| | image.repository | Thanos image repository and name | 'quay.io/thanos/thanos' **For Thanos version 0.6.0 or older change this to 'improbable/thanos'** | -| image.tag | Thanos image tag | v0.8.0 | +| image.tag | Thanos image tag | v0.8.1 | | image.pullPolicy | Image Kubernetes pull policy | IfNotPresent | | objstore | Configuration for the backend object storage in yaml format. Mutually exclusive with objstoreFile. | {} | | objstoreFile | Configuration for the backend object storage in string format. Mutually exclusive with objstore. | "" |