The bundled `postgresql-ha` sub-chart was the only HA-ready database option, but it pinned us to a Bitnami chart whose images are no longer freely distributed, and it bundled repmgr and pgpool into the release. Operating a Postgres cluster through a Helm release also means the chart has to reimplement failover, backup and upgrade orchestration that a dedicated operator already solves. CloudNativePG is the de-facto standard operator for Postgres on Kubernetes and handles instance management, streaming replication, switchover and rolling upgrades itself. The operator is deliberately *not* part of this chart: cluster-scoped CRDs and controllers do not belong into an application release and would conflict with an operator that is already installed. The chart only renders the namespaced `Cluster` resource, so the operator can be managed independently. Because the operator cannot be assumed to be present, `cloudnativePG.enabled` defaults to `false`. Existing users of `postgresql` or an external database are therefore unaffected. Credentials follow the chart-wide `secrets.*` convention. Only the password is read from a Secret, because CloudNativePG requires `bootstrap.initdb.database` and `bootstrap.initdb.owner` as literals in the `Cluster` spec and cannot resolve them from a Secret. The password is injected into the `init-app-ini` container as `GITEA__database__PASSWD` instead of being written into the generated `app.ini`. BREAKING CHANGE: The `postgresql-ha` sub-chart and all `postgresql-ha.*` values have been removed. There is no in-place migration path between the two deployments: dump the database of the old `postgresql-ha` release with `pg_dump`, remove the `postgresql-ha` values, deploy the chart with `cloudnativePG.enabled=true` and restore the dump. Setting `postgresql-ha` now fails the release with a pointer to the changelog. Co-authored-by: Copilot <copilot@github.com>
163 lines
7.4 KiB
YAML
163 lines
7.4 KiB
YAML
{{- if .Values.checkDeprecation -}}
|
|
{{/* CUSTOM PROBES */}}
|
|
{{- if .Values.gitea.customLivenessProbe -}}
|
|
{{- fail "`gitea.customLivenessProbe` does no longer exist. Please refer to the changelog and configure `gitea.livenessProbe` instead." -}}
|
|
{{- end -}}
|
|
{{- if .Values.gitea.customReadinessProbe -}}
|
|
{{- fail "`gitea.customReadinessProbe` does no longer exist. Please refer to the changelog and configure `gitea.readinessProbe` instead." -}}
|
|
{{- end -}}
|
|
{{- if .Values.gitea.customStartupProbe -}}
|
|
{{- fail "`gitea.customStartupProbe` does no longer exist. Please refer to the changelog and configure `gitea.startupProbe` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* LDAP SOURCES */}}
|
|
{{- if kindIs "map" .Values.gitea.ldap -}}
|
|
{{- fail "You can configure multiple LDAP sources. Please refer to the changelog and switch `gitea.ldap` from object to array notation." -}}
|
|
{{- end -}}
|
|
|
|
{{/* OAUTH SOURCES */}}
|
|
{{- if kindIs "map" .Values.gitea.oauth -}}
|
|
{{- fail "You can configure multiple OAuth sources. Please refer to the changelog and switch `gitea.oauth` from object to array notation." -}}
|
|
{{- end -}}
|
|
|
|
{{/* BUILTIN */}}
|
|
{{- if .Values.gitea.cache -}}
|
|
{{- if .Values.gitea.cache.builtIn -}}
|
|
{{- fail "`gitea.cache.builtIn` does no longer exist. Please use `memcached` at root level instead." -}}
|
|
{{- end -}}
|
|
{{- end -}}
|
|
{{- if .Values.gitea.database -}}
|
|
{{- if .Values.gitea.database.builtIn -}}
|
|
{{- fail "`gitea.database.builtIn` does no longer exist. Builtin databases can be configured inside the dependencies itself. Please refer to the changelog." -}}
|
|
{{- end -}}
|
|
{{- end -}}
|
|
{{- if .Values.gitea.admin -}}
|
|
{{- fail "`gitea.admin` does no longer exist. Please refer to the changelog and configure `secrets.admin` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* SIGNING */}}
|
|
{{- if .Values.signing -}}
|
|
{{- fail "`signing` does no longer exist. Please refer to the changelog and configure `secrets.gpg` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* AFFINITY */}}
|
|
{{- if .Values.affinity -}}
|
|
{{- fail "`affinity` does no longer exist. Please refer to the changelog and configure `deployment.affinity` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* CONTAINER SECURITY CONTEXT */}}
|
|
{{- if .Values.containerSecurityContext -}}
|
|
{{- fail "`containerSecurityContext` does no longer exist. Please refer to the changelog and configure `deployment.gitea.securityContext` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* DEPLOYMENT ENV */}}
|
|
{{- if .Values.deployment.env -}}
|
|
{{- fail "`deployment.env` does no longer exist. Please refer to the changelog and configure `deployment.gitea.env` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* DNS CONFIG */}}
|
|
{{- if .Values.dnsConfig -}}
|
|
{{- fail "`dnsConfig` does no longer exist. Please refer to the changelog and configure `deployment.dnsConfig` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* EXTRA CONTAINER VOLUME MOUNTS */}}
|
|
{{- if .Values.extraContainerVolumeMounts -}}
|
|
{{- fail "`extraContainerVolumeMounts` does no longer exist. Please refer to the changelog and configure `deployment.gitea.volumeMounts` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* EXTRA INIT VOLUME MOUNTS */}}
|
|
{{- if .Values.extraInitVolumeMounts -}}
|
|
{{- fail "`extraInitVolumeMounts` does no longer exist. Please refer to the changelog and configure `deployment.<initContainer>.volumeMounts` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* EXTRA VOLUME MOUNTS */}}
|
|
{{- if .Values.extraVolumeMounts -}}
|
|
{{- fail "`extraVolumeMounts` does no longer exist. Please refer to the changelog and configure `deployment.gitea.volumeMounts` and `deployment.<initContainer>.volumeMounts` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* EXTRA VOLUMES */}}
|
|
{{- if .Values.extraVolumes -}}
|
|
{{- fail "`extraVolumes` does no longer exist. Please refer to the changelog and configure `deployment.volumes` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* INGRESS CLASS NAME */}}
|
|
{{- if hasKey .Values.ingress "className" -}}
|
|
{{- fail "`ingress.className` does no longer exist. Please refer to the changelog and configure `ingress.ingressClassName` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* NODE SELECTOR */}}
|
|
{{- if .Values.nodeSelector -}}
|
|
{{- fail "`nodeSelector` does no longer exist. Please refer to the changelog and configure `deployment.nodeSelector` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* OPENSHIFT HOST USERS */}}
|
|
{{- if hasKey .Values.openshift "hostUsers" -}}
|
|
{{- fail "`openshift.hostUsers` does no longer exist. Please refer to the changelog and configure `deployment.hostUsers` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* POSTGRESQL HA */}}
|
|
{{- if index .Values "postgresql-ha" -}}
|
|
{{- fail "`postgresql-ha` does no longer exist. Please refer to the changelog and configure `cloudnativePG` instead, which requires the CloudNativePG operator to be installed in the cluster." -}}
|
|
{{- end -}}
|
|
|
|
{{/* PRIORITY CLASS NAME */}}
|
|
{{- if .Values.priorityClassName -}}
|
|
{{- fail "`priorityClassName` does no longer exist. Please refer to the changelog and configure `deployment.priorityClassName` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* POD SECURITY CONTEXT */}}
|
|
{{- if .Values.podSecurityContext -}}
|
|
{{- fail "`podSecurityContext` does no longer exist. Please refer to the changelog and configure `deployment.securityContext` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* POST EXTRA INIT CONTAINERS */}}
|
|
{{- if .Values.postExtraInitContainers -}}
|
|
{{- fail "`postExtraInitContainers` does no longer exist. Please refer to the changelog and append an entry with a `container` key to `deployment.initContainers` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* PRE EXTRA INIT CONTAINERS */}}
|
|
{{- if .Values.preExtraInitContainers -}}
|
|
{{- fail "`preExtraInitContainers` does no longer exist. Please refer to the changelog and prepend an entry with a `container` key to `deployment.initContainers` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* RESOURCES */}}
|
|
{{- if .Values.resources -}}
|
|
{{- fail "`resources` does no longer exist. Please refer to the changelog and configure `deployment.gitea.resources` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* REPLICA COUNT */}}
|
|
{{- if .Values.replicaCount -}}
|
|
{{- fail "`replicaCount` does no longer exist. Please refer to the changelog and configure `deployment.replicas` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* SCHEDULER NAME */}}
|
|
{{- if .Values.schedulerName -}}
|
|
{{- fail "`schedulerName` does no longer exist. Please refer to the changelog and configure `deployment.schedulerName` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* SECURITY CONTEXT */}}
|
|
{{- if .Values.securityContext -}}
|
|
{{- fail "`securityContext` does no longer exist. Please refer to the changelog and configure `deployment.securityContext` and `deployment.gitea.securityContext` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* STRATEGY */}}
|
|
{{- if .Values.strategy -}}
|
|
{{- fail "`strategy` does no longer exist. Please refer to the changelog and configure `deployment.strategy` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* TEST */}}
|
|
{{- if .Values.test -}}
|
|
{{- fail "`test` does no longer exist. Please refer to the changelog. The `helm test` connection Pod has been removed without replacement." -}}
|
|
{{- end -}}
|
|
|
|
{{/* TOLERATIONS */}}
|
|
{{- if .Values.tolerations -}}
|
|
{{- fail "`tolerations` does no longer exist. Please refer to the changelog and configure `deployment.tolerations` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{/* TOPOLOGY SPREAD CONSTRAINTS */}}
|
|
{{- if .Values.topologySpreadConstraints -}}
|
|
{{- fail "`topologySpreadConstraints` does no longer exist. Please refer to the changelog and configure `deployment.topologySpreadConstraints` instead." -}}
|
|
{{- end -}}
|
|
{{- end -}}
|