feat: create db-init.yaml for paperless-ngx
This commit is contained in:
parent
6cd445a691
commit
73a2d13251
1 changed files with 21 additions and 0 deletions
21
charts/paperless-ngx/templates/db-init.yaml
Normal file
21
charts/paperless-ngx/templates/db-init.yaml
Normal file
|
@ -0,0 +1,21 @@
|
|||
apiVersion: batch/v1
|
||||
kind: Job
|
||||
metadata:
|
||||
name: {{ include "paperless-ngx.fullname" . }}-db-init
|
||||
labels:
|
||||
{{- include "paperless-ngx.labels" . | nindent 4 }}
|
||||
annotations:
|
||||
"helm.sh/hook": pre-install
|
||||
"helm.sh/hook-delete-policy": before-hook-creation,hook-succeeded
|
||||
spec:
|
||||
template:
|
||||
spec:
|
||||
restartPolicy: Never
|
||||
containers:
|
||||
- name: general-db-init
|
||||
image: "{{ .Values.initContainers.dbInit.image.repository }}:{{ .Values.initContainers.dbInit.image.tag }}"
|
||||
envFrom:
|
||||
- secretRef:
|
||||
name: {{ .Values.postgres.secretName }}
|
||||
# Tolerate a few failures, adjust the number as needed
|
||||
backoffLimit: 3
|
Loading…
Reference in a new issue