mirror of
https://github.com/dredx/prole.git
synced 2026-09-27 23:14:31 +00:00
- Makefile: Added 'init' and 'deploy' targets for k3s parity and Gitea staging. - OpenTofu: Fixed namespace handling in k3s main.tf to prevent metadata overwrites. - UI: Added 'GitOps' and 'Database Options' configuration screens. - Core: Enhanced monitoring, milestones, and environment handling for new services. - Supabase: Integrated full Helm chart and manifest rendering logic. - Gitea: Added deployment scripts and GitOps sync support. - Database: Added Percona/Postgres Dockerfile templates and improved TDE scripts. - Tests: Added coverage for new UI screens and navigation flows.
53 lines
1.5 KiB
Smarty
53 lines
1.5 KiB
Smarty
{{/*
|
|
Return the PVC name for a given workload.
|
|
If persistence.existingClaim is set, use it.
|
|
Otherwise generate the default name.
|
|
Usage: {{ include "supabase.pvc.name" (dict "root" $ "name" "alias") }}
|
|
*/}}
|
|
{{- define "supabase.pvc.name" -}}
|
|
{{- $root := .root -}}
|
|
{{- $name := .name -}}
|
|
{{- $persistence := index $root.Values.persistence $name -}}
|
|
|
|
{{- if $persistence.existingClaim -}}
|
|
{{- $persistence.existingClaim -}}
|
|
{{- else -}}
|
|
{{- printf "%s-%s" (include "supabase.fullname" $root) $name | trunc 63 | trimSuffix "-" -}}
|
|
{{- end -}}
|
|
{{- end -}}
|
|
|
|
{{/*
|
|
Create a PVC for a given workload name.
|
|
Usage: {{ include "supabase.pvc" (dict "root" $ "name" "workload" "enabled": "true") }}
|
|
*/}}
|
|
{{- define "supabase.pvc" -}}
|
|
{{- $root := .root -}}
|
|
{{- $name := .name -}}
|
|
{{- $enabled := .enabled -}}
|
|
{{- $persistence := index $root.Values.persistence $name -}}
|
|
|
|
{{- if and $enabled $persistence.enabled (not $persistence.existingClaim) -}}
|
|
apiVersion: v1
|
|
kind: PersistentVolumeClaim
|
|
metadata:
|
|
name: {{ include "supabase.pvc.name" (dict "root" $root "name" $name) }}
|
|
labels:
|
|
{{- include "supabase.labels" $root | nindent 4 }}
|
|
{{- with $persistence.annotations }}
|
|
annotations:
|
|
{{- toYaml . | nindent 4 }}
|
|
{{- end }}
|
|
spec:
|
|
{{- if $persistence.storageClassName }}
|
|
storageClassName: {{ $persistence.storageClassName }}
|
|
{{- end }}
|
|
accessModes:
|
|
{{- range $persistence.accessModes }}
|
|
- {{ . | quote }}
|
|
{{- end }}
|
|
resources:
|
|
requests:
|
|
storage: {{ $persistence.size | quote }}
|
|
{{- end }}
|
|
{{- end }}
|