Skip to content

Commit

Permalink
statefull-editoast: fix liveness command
Browse files Browse the repository at this point in the history
Signed-off-by: Florian Amsallem <[email protected]>
  • Loading branch information
flomonster authored and ElysaSrc committed Oct 21, 2024
1 parent 9439b01 commit feed32a
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 25 deletions.
14 changes: 10 additions & 4 deletions templates/stateful_editoast/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,18 +38,24 @@ spec:
containerPort: {{ .Values.services.statefulEditoast.service.port }}
protocol: TCP

{{- if not .Values.services.statefulEditoast.livenessProbe.disabled }}
livenessProbe:
httpGet:
path: /health
port: http
exec:
command:
- /bin/sh
- "-c"
- 'ps ax | grep -q "editoast" && /usr/local/bin/editoast healthcheck'
initialDelaySeconds: {{ .Values.services.statefulEditoast.livenessProbe.initialDelaySeconds }}
periodSeconds: {{ .Values.services.statefulEditoast.livenessProbe.periodSeconds }}
timeoutSeconds: {{ .Values.services.statefulEditoast.livenessProbe.timeoutSeconds }}
{{- end }}

{{- if not .Values.services.statefulEditoast.readinessProbe.disabled }}
readinessProbe:
httpGet:
path: /health
port: http
{{- end }}

env:
- name: EDITOAST_PORT
Expand Down Expand Up @@ -95,7 +101,7 @@ spec:
{{- with .Values.services.statefulEditoast.env | default dict }}
{{- toYaml . | nindent 12 }}
{{- end }}

resources:
{{- toYaml .Values.services.statefulEditoast.resources | nindent 12 }}

Expand Down
44 changes: 23 additions & 21 deletions values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ services:
api_address: "0.0.0.0:80"
default_message_ttl:
max_length:
max_length_bytes:
max_length_bytes:
annotations: {}
labels: {}
nodeSelector: {}
Expand Down Expand Up @@ -87,26 +87,6 @@ services:
autoscaling:
type: NoScaling

statefulEditoast:
enabled: true
replicaCount: 1
service:
type: ClusterIP
port: 80
targetPort: 80
livenessProbe:
disabled: false
initialDelaySeconds: 0
periodSeconds: 10
timeoutSeconds: 1
annotations: {}
labels: {}
nodeSelector: {}
tolerations: []
affinity: {}
resources: {}
env: []

gateway:
enabled: true
replicaCount: 1
Expand Down Expand Up @@ -180,3 +160,25 @@ services:
affinity: {}
resources: {}
env: []

statefulEditoast:
enabled: true
replicaCount: 1
service:
type: ClusterIP
port: 80
targetPort: 80
livenessProbe:
disabled: false
initialDelaySeconds: 0
periodSeconds: 10
timeoutSeconds: 1
readinessProbe:
disabled: false
annotations: {}
labels: {}
nodeSelector: {}
tolerations: []
affinity: {}
resources: {}
env: []

0 comments on commit feed32a

Please sign in to comment.