diff --git a/README.md b/README.md index fe7aeee..0fb82e7 100644 --- a/README.md +++ b/README.md @@ -47,7 +47,7 @@ Please note the following changes in the Chart to upgrade successfully. :warning The app.ini generation has changed and now utilizes the environment-to-ini script provided by newer Gitea versions. -:boom: The Helm Chart now requires Gitea versions of at least 1.11.0. +> :boom: The Helm Chart now requires Gitea versions of at least 1.11.0. This change ensures, that the app.ini is now persistent. @@ -61,11 +61,32 @@ automatically in certain situations: - Existing installs: The secrets won't be deployed, neither via configuration nor via auto generation. We explicitly prevent to set new secrets. -:rotating_light: It would be possible to set new secret keys manually by entering +> :rotating_light: It would be possible to set new secret keys manually by entering the running container and rewriting the app.ini by hand. However, this it is not advisable to do so for existing installations. Certain settings like _LDAP_ would not be readable anymore. +### Probes + +> :boom: `gitea.customLivenessProbe`, `gitea.customReadinessProbe` and `gitea.customStartupProbe` +have been removed. + +They are replaced by the settings `gitea.livenessProbe`, `gitea.readinessProbe` +and `gitea.startupProbe` which are now fully configurable and used _as-is_ for +a Chart deployment. +If you have customized their values instead of using the `custom` prefixed settings, +please ensure that you remove the `enabled` property from each of them. + +In case you want to disable one of these probes, let's say the `livenessProbe`, add +the following to your values. The `podAnnotation` is just there to have a bit more +context. + +```diff +gitea: ++ livenessProbe: + podAnnotations: {} +``` + ## Chart upgrade from 3.x.x to 4.0.0 :warning: The most recent `4.0.0` update brings some breaking changes. Please note @@ -635,29 +656,44 @@ gitea: Configure Liveness, Readiness and Startup [Probes](https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/). +#### Liveness probe + +- Default status: Enabled +- Default action: tcp socket connect + | Parameter | Description | Default | | ------------------------------------------ | -------------------------------------------------------------------- | ------- | -| `gitea.livenessProbe.enabled` | Enable liveness probe | `true` | | `gitea.livenessProbe.initialDelaySeconds` | Delay before probe start | `200` | | `gitea.livenessProbe.timeoutSeconds` | probe timeout | `1` | | `gitea.livenessProbe.periodSeconds` | period between probes | `10` | | `gitea.livenessProbe.successThreshold` | Minimum consecutive success probes | `1` | | `gitea.livenessProbe.failureThreshold` | Minimum consecutive error probes | `10` | -| `gitea.readinessProbe.enabled` | Enable readiness probe | `true` | + +#### Readiness probe + +- Default status: Enabled +- Default action: tcp socket connect + +| Parameter | Description | Default | +| ------------------------------------------ | -------------------------------------------------------------------- | ------- | | `gitea.readinessProbe.initialDelaySeconds` | Delay before probe start | `5` | | `gitea.readinessProbe.timeoutSeconds` | probe timeout | `1` | | `gitea.readinessProbe.periodSeconds` | period between probes | `10` | | `gitea.readinessProbe.successThreshold` | Minimum consecutive success probes | `1` | | `gitea.readinessProbe.failureThreshold` | Minimum consecutive error probes | `3` | -| `gitea.startupProbe.enabled` | Enable startup probe | `false` | + +#### Startup probe + +- Default status: Disabled +- Default action: tcp socket connect + +| Parameter | Description | Default | +| ------------------------------------------ | -------------------------------------------------------------------- | ------- | | `gitea.startupProbe.initialDelaySeconds` | Delay before probe start | `60` | | `gitea.startupProbe.timeoutSeconds` | probe timeout | `1` | | `gitea.startupProbe.periodSeconds` | period between probes | `10` | | `gitea.startupProbe.successThreshold` | Minimum consecutive success probes | `1` | | `gitea.startupProbe.failureThreshold` | Minimum consecutive error probes | `10` | -| `gitea.customLivenessProbe` | Custom liveness probe (needs `gitea.livenessProbe.enabled: false`) | | -| `gitea.customReadinessProbe` | Custom readiness probe (needs `gitea.readinessProbe.enabled: false`) | | -| `gitea.customStartupProbe` | Custom startup probe (needs `gitea.startupProbe.enabled: false`) | | ### Memcached BuiltIn diff --git a/templates/gitea/statefulset.yaml b/templates/gitea/statefulset.yaml index 3b006b2..1d5aa18 100644 --- a/templates/gitea/statefulset.yaml +++ b/templates/gitea/statefulset.yaml @@ -192,44 +192,17 @@ spec: - name: profiler containerPort: 6060 {{- end }} - {{- if .Values.gitea.livenessProbe.enabled }} + {{- if .Values.gitea.livenessProbe }} livenessProbe: - tcpSocket: - port: http - initialDelaySeconds: {{ .Values.gitea.livenessProbe.initialDelaySeconds }} - periodSeconds: {{ .Values.gitea.livenessProbe.periodSeconds }} - timeoutSeconds: {{ .Values.gitea.livenessProbe.timeoutSeconds }} - successThreshold: {{ .Values.gitea.livenessProbe.successThreshold }} - failureThreshold: {{ .Values.gitea.livenessProbe.failureThreshold }} - {{- else if .Values.gitea.customLivenessProbe }} - livenessProbe: - {{- toYaml .Values.gitea.customLivenessProbe | nindent 12 }} + {{- toYaml .Values.gitea.livenessProbe | nindent 12 }} {{- end }} - {{- if .Values.gitea.readinessProbe.enabled }} + {{- if .Values.gitea.readinessProbe }} readinessProbe: - tcpSocket: - port: http - initialDelaySeconds: {{ .Values.gitea.readinessProbe.initialDelaySeconds }} - periodSeconds: {{ .Values.gitea.readinessProbe.periodSeconds }} - timeoutSeconds: {{ .Values.gitea.readinessProbe.timeoutSeconds }} - successThreshold: {{ .Values.gitea.readinessProbe.successThreshold }} - failureThreshold: {{ .Values.gitea.readinessProbe.failureThreshold }} - {{- else if .Values.gitea.customReadinessProbe }} - readinessProbe: - {{- toYaml .Values.gitea.customReadinessProbe | nindent 12 }} + {{- toYaml .Values.gitea.readinessProbe | nindent 12 }} {{- end }} - {{- if .Values.gitea.startupProbe.enabled }} + {{- if .Values.gitea.startupProbe }} startupProbe: - tcpSocket: - port: http - initialDelaySeconds: {{ .Values.gitea.startupProbe.initialDelaySeconds }} - periodSeconds: {{ .Values.gitea.startupProbe.periodSeconds }} - timeoutSeconds: {{ .Values.gitea.startupProbe.timeoutSeconds }} - successThreshold: {{ .Values.gitea.startupProbe.successThreshold }} - failureThreshold: {{ .Values.gitea.startupProbe.failureThreshold }} - {{- else if .Values.gitea.customStartupProbe }} - startupProbe: - {{- toYaml .Values.gitea.customStartupProbe | nindent 12 }} + {{- toYaml .Values.gitea.startupProbe | nindent 12 }} {{- end }} resources: {{- toYaml .Values.resources | nindent 12 }} diff --git a/values.yaml b/values.yaml index d6e7a53..fabc055 100644 --- a/values.yaml +++ b/values.yaml @@ -207,49 +207,32 @@ gitea: builtIn: enabled: true + # Modify the liveness probe for your needs or completely disable it by commenting out. livenessProbe: - enabled: true + tcpSocket: + port: http initialDelaySeconds: 200 timeoutSeconds: 1 periodSeconds: 10 successThreshold: 1 failureThreshold: 10 + + # Modify the readiness probe for your needs or completely disable it by commenting out. readinessProbe: - enabled: true + tcpSocket: + port: http initialDelaySeconds: 5 timeoutSeconds: 1 periodSeconds: 10 successThreshold: 1 failureThreshold: 3 - startupProbe: - enabled: false - initialDelaySeconds: 60 - timeoutSeconds: 1 - periodSeconds: 10 - successThreshold: 1 - failureThreshold: 10 - # customLivenessProbe: - # httpGet: - # path: /user/login - # port: http - # initialDelaySeconds: 60 - # periodSeconds: 10 - # successThreshold: 1 - # failureThreshold: 10 - # customReadinessProbe: - # httpGet: - # path: /user/login - # port: http - # initialDelaySeconds: 5 - # periodSeconds: 10 - # successThreshold: 1 - # failureThreshold: 3 - # customStartupProbe: - # httpGet: - # path: /user/login + # # Uncomment the startup probe to enable and modify it for your needs. + # startupProbe: + # tcpSocket: # port: http # initialDelaySeconds: 60 + # timeoutSeconds: 1 # periodSeconds: 10 # successThreshold: 1 # failureThreshold: 10