mirror of
https://github.com/truenas/charts.git
synced 2026-05-16 14:12:59 +08:00
Upgraded catalog item(s)
This commit upgrades nextcloud catalog item(s).
This commit is contained in:
49
test/nextcloud/1.3.12/templates/_postgres.tpl
Normal file
49
test/nextcloud/1.3.12/templates/_postgres.tpl
Normal file
@@ -0,0 +1,49 @@
|
||||
{{/*
|
||||
Get Nextloud Postgres Database Name
|
||||
*/}}
|
||||
{{- define "postgres.DatabaseName" -}}
|
||||
{{- print "nextcloud" -}}
|
||||
{{- end -}}
|
||||
|
||||
|
||||
{{- define "postgres.imageName" -}}
|
||||
{{- print "postgres:13.1" -}}
|
||||
{{- end -}}
|
||||
|
||||
|
||||
{{/*
|
||||
Retrieve postgres backup name
|
||||
This will return a unique name based on revision and chart numbers specified.
|
||||
*/}}
|
||||
{{- define "postgres.backupName" -}}
|
||||
{{- $upgradeDict := .Values.ixChartContext.upgradeMetadata -}}
|
||||
{{- printf "postgres-backup-from-%s-to-%s-revision-%d" $upgradeDict.oldChartVersion $upgradeDict.newChartVersion (int64 $upgradeDict.preUpgradeRevision) -}}
|
||||
{{- end }}
|
||||
|
||||
|
||||
{{/*
|
||||
Retrieve postgres credentials for environment variables configuration
|
||||
*/}}
|
||||
{{- define "postgres.envVariableConfiguration" -}}
|
||||
{{ $envList := list }}
|
||||
{{ $envList = mustAppend $envList (dict "name" "POSTGRES_USER" "valueFromSecret" true "secretName" "db-details" "secretKey" "db-user") }}
|
||||
{{ $envList = mustAppend $envList (dict "name" "POSTGRES_PASSWORD" "valueFromSecret" true "secretName" "db-details" "secretKey" "db-password") }}
|
||||
{{ include "common.containers.environmentVariables" (dict "environmentVariables" $envList) }}
|
||||
{{- end -}}
|
||||
|
||||
|
||||
{{/*
|
||||
Retrieve postgres volume configuration
|
||||
*/}}
|
||||
{{- define "postgres.volumeConfiguration" -}}
|
||||
{{ include "common.storage.configureAppVolumes" (dict "appVolumeMounts" .Values.postgresAppVolumeMounts "emptyDirVolumes" .Values.emptyDirVolumes "ixVolumes" .Values.ixVolumes) | nindent 0 }}
|
||||
{{- end -}}
|
||||
|
||||
|
||||
{{/*
|
||||
Retrieve postgres volume mounts configuration
|
||||
*/}}
|
||||
{{- define "postgres.volumeMountsConfiguration" -}}
|
||||
{{ include "common.storage.configureAppVolumeMountsInContainer" (dict "appVolumeMounts" .Values.postgresAppVolumeMounts ) | nindent 0 }}
|
||||
{{- end -}}
|
||||
|
||||
Reference in New Issue
Block a user