Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Readiness + Startup probes #804

Open
wants to merge 19 commits into
base: main
Choose a base branch
from
42 changes: 31 additions & 11 deletions infra/helm/meshdb/templates/meshweb.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,18 +47,38 @@ spec:
mountPath: /opt/meshdb/static
{{ if eq .Values.meshweb.liveness_probe "true" }}
livenessProbe:
exec:
command:
- curl
- http://127.0.0.1:{{ .Values.meshweb.port }}/api/v1
periodSeconds: 3
initialDelaySeconds: 4
timeoutSeconds: 3
{{ end }}
livenessProbe:
{{- toYaml .Values.livenessProbe | nindent 12 }}
exec:
command:
- bash
- -c
- 'curl http://127.0.0.1:{{ .Values.meshweb.port }}/api/v1/ -H "Host: db.nycmesh.net" -s | grep meshin'
periodSeconds: 10
initialDelaySeconds: 30
timeoutSeconds: 3
{{ end }}
{{ if eq .Values.meshweb.readiness_probe "true" }}
readinessProbe:
{{- toYaml .Values.readinessProbe | nindent 12 }}
exec:
command:
- bash
- -c
- 'curl http://127.0.0.1:{{ .Values.meshweb.port }}/api/v1/ -H "Host: db.nycmesh.net" -s | grep meshin'
periodSeconds: 3
initialDelaySeconds: 10
timeoutSeconds: 3
{{ end }}
{{ if eq .Values.meshweb.startup_probe "true" }}
startupProbe:
exec:
command:
- bash
- -c
- 'curl http://127.0.0.1:{{ .Values.meshweb.port }}/api/v1/ -H "Host: db.nycmesh.net" -s | grep meshin'
periodSeconds: 3
initialDelaySeconds: 20
timeoutSeconds: 3
failureThreshold: 20
{{ end }}
resources:
{{- toYaml .Values.meshweb.resources | nindent 12 }}
volumes:
Expand Down
2 changes: 2 additions & 0 deletions infra/helm/meshdb/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ meshweb:
static_pvc_name: "meshdb-static-pvc"
static_pvc_size: "1Gi"
liveness_probe: "true"
readiness_probe: "true"
startup_probe: "true"
image:
repository: willnilges/meshdb
tag: main
Expand Down
Loading