Skip to content

Commit 6a67898

Browse files
committed
Provide new/default values for Probes #22
1 parent 78e0f0f commit 6a67898

File tree

4 files changed

+125
-6
lines changed

4 files changed

+125
-6
lines changed

charts/cryptpad/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ type: application
2121
# This is the chart version. This version number should be incremented each time you make changes
2222
# to the chart and its templates, including the app version.
2323
# Versions are expected to follow Semantic Versioning (https://semver.org/)
24-
version: 0.0.13
24+
version: 0.0.14
2525

2626
# This is the version number of the application being deployed. This version number should be
2727
# incremented each time you make changes to the application. Versions are not expected to

charts/cryptpad/README.md

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
CryptPad is a collaboration office suite that is end-to-end-encrypted and open-source.
44

5-
![Version: 0.0.13](https://img.shields.io/badge/Version-0.0.13-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square)
5+
![Version: 0.0.14](https://img.shields.io/badge/Version-0.0.14-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square)
66

77
## Installing the Chart
88

@@ -119,6 +119,30 @@ application_config:
119119
| persistence.enabled | bool | `true` | Enable the persistence |
120120
| podAnnotations | object | `{}` | Annotations for the Pod |
121121
| podSecurityContext | object | `{"fsGroup":4001}` | Security context for the Pod |
122+
| probes.liveness.enabled | bool | `true` | Enable liveness probe |
123+
| probes.liveness.failureThreshold | int | `5` | Failure threshold for liveness probe |
124+
| probes.liveness.httpGet.enabled | bool | `true` | If enabled uses httpGet to check, if false uses tcpSocket checking. |
125+
| probes.liveness.httpGet.path | string | `"/"` | Path to be tested with HTTP GET request |
126+
| probes.liveness.initialDelaySeconds | int | `0` | Initial delay seconds for liveness probe |
127+
| probes.liveness.periodSeconds | int | `10` | Period seconds for liveness probe |
128+
| probes.liveness.successThreshold | int | `1` | Success threshold for liveness probe |
129+
| probes.liveness.timeoutSeconds | int | `1` | Timeout seconds for liveness probe |
130+
| probes.readiness.enabled | bool | `true` | Enable readiness probe |
131+
| probes.readiness.failureThreshold | int | `5` | Failure threshold for readiness probe |
132+
| probes.readiness.httpGet.enabled | bool | `true` | If enabled uses httpGet to check, if false uses tcpSocket checking. |
133+
| probes.readiness.httpGet.path | string | `"/"` | Path to be tested with HTTP GET request |
134+
| probes.readiness.initialDelaySeconds | int | `0` | Initial delay seconds for readiness probe |
135+
| probes.readiness.periodSeconds | int | `10` | Period seconds for readiness probe |
136+
| probes.readiness.successThreshold | int | `1` | Success threshold for readiness probe |
137+
| probes.readiness.timeoutSeconds | int | `1` | Timeout seconds for readiness probe |
138+
| probes.startup.enabled | bool | `true` | Enable startup probe |
139+
| probes.startup.failureThreshold | int | `5` | Failure threshold for startup probe |
140+
| probes.startup.httpGet.enabled | bool | `false` | If enabled uses httpGet to check, if false uses tcpSocket checking. |
141+
| probes.startup.httpGet.path | string | `"/"` | Path to be tested with HTTP GET request |
142+
| probes.startup.initialDelaySeconds | int | `0` | Initial delay seconds for startup probe |
143+
| probes.startup.periodSeconds | int | `10` | Period seconds for startup probe |
144+
| probes.startup.successThreshold | int | `1` | Success threshold for startup probe |
145+
| probes.startup.timeoutSeconds | int | `1` | Timeout seconds for startup probe |
122146
| replicaCount | int | `1` | Number of replicas |
123147
| resources | object | `{}` | Specify default resources. We usually recommend not to specify default resources and to leave this as a conscious choice for the user. This also increases chances charts run on environments with little resources, such as Minikube. |
124148
| securityContext | object | `{}` | Security context |

charts/cryptpad/templates/cryptpad.yaml

Lines changed: 44 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,14 +82,54 @@ spec:
8282
- name: {{ .Values.service.websocket.internalPort }}
8383
containerPort: {{ .Values.service.websocket.containerPort }}
8484
protocol: TCP
85+
{{- if .Values.probes.startup.enabled }}
86+
startupProbe:
87+
{{- if .Values.probes.startup.httpGet.enabled }}
88+
httpGet:
89+
path: {{ .Values.probes.startup.httpGet.path }}
90+
port: {{ .Values.service.containerPort }}
91+
{{- else }}
92+
tcpSocket:
93+
port: {{ .Values.service.containerPort }}
94+
{{- end }}
95+
initialDelaySeconds: {{ .Values.probes.startup.initialDelaySeconds }}
96+
timeoutSeconds: {{ .Values.probes.startup.timeoutSeconds }}
97+
periodSeconds: {{ .Values.probes.startup.periodSeconds }}
98+
failureThreshold: {{ .Values.probes.startup.failureThreshold }}
99+
successThreshold: {{ .Values.probes.startup.successThreshold }}
100+
{{- end }}
101+
{{- if .Values.probes.liveness.enabled }}
85102
livenessProbe:
103+
{{- if .Values.probes.liveness.httpGet.enabled }}
86104
httpGet:
87-
path: /
88-
port: http
105+
path: {{ .Values.probes.liveness.httpGet.path }}
106+
port: {{ .Values.service.containerPort }}
107+
{{- else }}
108+
tcpSocket:
109+
port: {{ .Values.service.containerPort }}
110+
{{- end }}
111+
initialDelaySeconds: {{ .Values.probes.liveness.initialDelaySeconds }}
112+
timeoutSeconds: {{ .Values.probes.liveness.timeoutSeconds }}
113+
periodSeconds: {{ .Values.probes.liveness.periodSeconds }}
114+
failureThreshold: {{ .Values.probes.liveness.failureThreshold }}
115+
successThreshold: {{ .Values.probes.liveness.successThreshold }}
116+
{{- end }}
117+
{{- if .Values.probes.readiness.enabled }}
89118
readinessProbe:
119+
{{- if .Values.probes.readiness.httpGet.enabled }}
90120
httpGet:
91-
path: /
92-
port: http
121+
path: {{ .Values.probes.liveness.httpGet.path }}
122+
port: {{ .Values.service.containerPort }}
123+
{{- else }}
124+
tcpSocket:
125+
port: {{ .Values.service.containerPort }}
126+
{{- end }}
127+
initialDelaySeconds: {{ .Values.probes.readiness.initialDelaySeconds }}
128+
timeoutSeconds: {{ .Values.probes.readiness.timeoutSeconds }}
129+
periodSeconds: {{ .Values.probes.readiness.periodSeconds }}
130+
failureThreshold: {{ .Values.probes.readiness.failureThreshold }}
131+
successThreshold: {{ .Values.probes.readiness.successThreshold }}
132+
{{- end }}
93133
resources:
94134
{{- toYaml .Values.resources | nindent 12 }}
95135
volumeMounts:

charts/cryptpad/values.yaml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -240,3 +240,58 @@ persistence:
240240
selector: {}
241241
dataSource: {}
242242

243+
probes:
244+
startup:
245+
# -- Enable startup probe
246+
enabled: true
247+
httpGet:
248+
# -- If enabled uses httpGet to check, if false uses tcpSocket checking.
249+
enabled: false
250+
# -- Path to be tested with HTTP GET request
251+
path: /
252+
# -- Initial delay seconds for startup probe
253+
initialDelaySeconds: 0
254+
# -- Timeout seconds for startup probe
255+
timeoutSeconds: 1
256+
# -- Period seconds for startup probe
257+
periodSeconds: 10
258+
# -- Failure threshold for startup probe
259+
failureThreshold: 5
260+
# -- Success threshold for startup probe
261+
successThreshold: 1
262+
liveness:
263+
# -- Enable liveness probe
264+
enabled: true
265+
httpGet:
266+
# -- If enabled uses httpGet to check, if false uses tcpSocket checking.
267+
enabled: true
268+
# -- Path to be tested with HTTP GET request
269+
path: /
270+
# -- Initial delay seconds for liveness probe
271+
initialDelaySeconds: 0
272+
# -- Timeout seconds for liveness probe
273+
timeoutSeconds: 1
274+
# -- Period seconds for liveness probe
275+
periodSeconds: 10
276+
# -- Failure threshold for liveness probe
277+
failureThreshold: 5
278+
# -- Success threshold for liveness probe
279+
successThreshold: 1
280+
readiness:
281+
# -- Enable readiness probe
282+
enabled: true
283+
httpGet:
284+
# -- If enabled uses httpGet to check, if false uses tcpSocket checking.
285+
enabled: true
286+
# -- Path to be tested with HTTP GET request
287+
path: /
288+
# -- Initial delay seconds for readiness probe
289+
initialDelaySeconds: 0
290+
# -- Timeout seconds for readiness probe
291+
timeoutSeconds: 1
292+
# -- Period seconds for readiness probe
293+
periodSeconds: 10
294+
# -- Failure threshold for readiness probe
295+
failureThreshold: 5
296+
# -- Success threshold for readiness probe
297+
successThreshold: 1

0 commit comments

Comments
 (0)