2021-10-01 12:20:59 +00:00
|
|
|
{{/* Make sure all variables are set properly */}}
|
2021-10-09 21:43:48 +00:00
|
|
|
{{- include "common.setup" . }}
|
2021-10-01 12:20:59 +00:00
|
|
|
|
|
|
|
{{/* Render secrets for gitea */}}
|
|
|
|
{{- include "gitea.secrets" . }}
|
|
|
|
|
|
|
|
{{/* Render configmap for gitea */}}
|
|
|
|
{{- include "gitea.configmap" . }}
|
|
|
|
|
|
|
|
{{/* Append the general secret volumes to the volumes */}}
|
|
|
|
{{- define "gitea.initvolume" -}}
|
|
|
|
enabled: "true"
|
|
|
|
mountPath: "/secrets/ini"
|
|
|
|
readOnly: true
|
|
|
|
type: "custom"
|
|
|
|
volumeSpec:
|
|
|
|
secret:
|
|
|
|
secretName: {{ include "common.names.fullname" . }}-init
|
|
|
|
defaultMode: 0777
|
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{/* Append the general secret volumes to the volumes */}}
|
|
|
|
{{- define "gitea.configvolume" -}}
|
|
|
|
enabled: "true"
|
|
|
|
mountPath: "/secrets/config"
|
|
|
|
readOnly: true
|
|
|
|
type: "custom"
|
|
|
|
volumeSpec:
|
|
|
|
secret:
|
|
|
|
secretName: {{ include "common.names.fullname" . }}
|
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- $_ := set .Values.persistence "init" (include "gitea.initvolume" . | fromYaml) -}}
|
|
|
|
{{- $_ := set .Values.persistence "config" (include "gitea.configvolume" . | fromYaml) -}}
|
|
|
|
|
|
|
|
|
|
|
|
{{/* Render the templates */}}
|
2021-10-09 22:02:33 +00:00
|
|
|
{{ include "common.postSetup" . }}
|