_postgres.tpl 811 B

12345678910111213141516171819202122232425262728
  1. {{/*
  2. Get Nextloud Postgres Database Name
  3. */}}
  4. {{- define "postgres.DatabaseName" -}}
  5. {{- print "nextcloud" -}}
  6. {{- end -}}
  7. {{/*
  8. Postgres Selector labels
  9. */}}
  10. {{- define "nextcloud.postgres.selectorLabels" -}}
  11. app.kubernetes.io/name: {{ include "nextcloud.name" . }}-postgres
  12. app.kubernetes.io/instance: {{ .Release.Name }}-postgres
  13. {{- end }}
  14. {{- define "postgres.imageName" -}}
  15. {{- print "postgres:13.1" -}}
  16. {{- end -}}
  17. {{/*
  18. Retrieve postgres backup name
  19. This will return a unique name based on revision and chart numbers specified.
  20. */}}
  21. {{- define "postgres.backupName" -}}
  22. {{- $upgradeDict := .Values.ixChartContext.upgradeMetadata -}}
  23. {{- printf "postgres-backup-from-%s-to-%s-revision-%d" $upgradeDict.oldChartVersion $upgradeDict.newChartVersion (int64 $upgradeDict.preUpgradeRevision) -}}
  24. {{- end }}