Skip to content

Commit

Permalink
[sophora-server]: add flags to enable or disable probes (#104) (#105)
Browse files Browse the repository at this point in the history
* [sophora-server]: add flags to enable probes (#104)

* [sophora-server]: bump version (#104)

---------

Co-authored-by: Philip Dakowitz <[email protected]>
  • Loading branch information
hehu80 and philmtd committed Jul 9, 2024
1 parent f4c7ec5 commit fda2d53
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 16 deletions.
2 changes: 1 addition & 1 deletion charts/sophora-server/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 2.3.0
version: 2.3.1

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
Expand Down
30 changes: 15 additions & 15 deletions charts/sophora-server/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -282,35 +282,35 @@ spec:
- containerPort: 1199
name: rmi-registry
{{- end }}
{{- with .Values.livenessProbe }}
{{- if .Values.livenessProbe.enabled }}
livenessProbe:
httpGet:
path: /status/liveness
port: 1196
failureThreshold: {{ .failureThreshold }}
initialDelaySeconds: {{ .initialDelaySeconds }}
periodSeconds: {{ .periodSeconds }}
timeoutSeconds: {{ .timeoutSeconds }}
failureThreshold: {{ .Values.livenessProbe.failureThreshold }}
initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }}
periodSeconds: {{ .Values.livenessProbe.periodSeconds }}
timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }}
{{- end }}
{{- with .Values.readinessProbe }}
{{- if .Values.readinessProbe.enabled }}
readinessProbe:
httpGet:
path: /status/ready
port: 1196
failureThreshold: {{ .failureThreshold }}
initialDelaySeconds: {{ .initialDelaySeconds }}
periodSeconds: {{ .periodSeconds }}
timeoutSeconds: {{ .timeoutSeconds }}
failureThreshold: {{ .Values.readinessProbe.failureThreshold }}
initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }}
periodSeconds: {{ .Values.readinessProbe.periodSeconds }}
timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }}
{{- end }}
{{- with .Values.startupProbe }}
{{- if .Values.startupProbe.enabled }}
startupProbe:
httpGet:
path: /status/started
port: 1196
failureThreshold: {{ .failureThreshold }}
initialDelaySeconds: {{ .initialDelaySeconds }}
periodSeconds: {{ .periodSeconds }}
timeoutSeconds: {{ .timeoutSeconds }}
failureThreshold: {{ .Values.startupProbe.failureThreshold }}
initialDelaySeconds: {{ .Values.startupProbe.initialDelaySeconds }}
periodSeconds: {{ .Values.startupProbe.periodSeconds }}
timeoutSeconds: {{ .Values.startupProbe.timeoutSeconds }}
{{- end }}
{{ if and .Values.sophora.server.isClusterServer .Values.preStop.enabled -}}
lifecycle:
Expand Down
3 changes: 3 additions & 0 deletions charts/sophora-server/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -272,18 +272,21 @@ configInitializer:
envFrom:

startupProbe:
enabled: true
failureThreshold: 35
initialDelaySeconds: 10
timeoutSeconds: 5
periodSeconds: 5

readinessProbe:
enabled: true
failureThreshold: 15
initialDelaySeconds: 30
timeoutSeconds: 5
periodSeconds: 15

livenessProbe:
enabled: true
failureThreshold: 3
initialDelaySeconds: 60
timeoutSeconds: 10
Expand Down

0 comments on commit fda2d53

Please sign in to comment.