Commit 4144f04e authored by Thomas Beermann's avatar Thomas Beermann
Browse files

add missing template file

parent 9d451fce
Pipeline #142733 passed with stages
in 21 seconds
apiVersion: v1
name: hifiscp
version: 0.1.15
version: 0.1.16
description: A Helm chart to deploy the HIFIS Cloud Portal Backend and Frontend
keywords:
- HIFIS
......
{{- if .Values.cerebrum.dbBackup.enabled -}}
apiVersion: batch/v1beta1
kind: CronJob
metadata:
name: {{ .Release.Name }}-db-backup
labels:
app: {{ template "hifiscp.name" . }}-db-backup
chart: {{ template "hifiscp.chart" . }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
spec:
schedule: "{{ .Values.cerebrum.dbBackup.schedule }}"
jobTemplate:
spec:
template:
spec:
containers:
- name: db-backup
image: {{ .Values.cerebrum.dbBackup.image.repository }}:{{ .Values.cerebrum.dbBackup.image.tag }}
imagePullPolicy: {{ .Values.cerebrum.dbBackup.image.pullPolicy }}
env:
{{- if .Values.cerebrum.config.mongodb.database }}
- name: MONGODB_DATABASE
value: {{ .Values.cerebrum.config.mongodb.database | quote }}
{{- end }}
{{- if .Values.cerebrum.config.mongodb.host }}
- name: MONGODB_HOST
value: {{ .Values.cerebrum.config.mongodb.host | quote }}
{{- end }}
{{- if .Values.cerebrum.config.mongodb.port }}
- name: MONGODB_PORT
value: {{ .Values.cerebrum.config.mongodb.port | quote }}
{{- end }}
{{- if .Values.cerebrum.config.mongodb.authdb }}
- name: MONGODB_AUTHDB
value: {{ .Values.cerebrum.config.mongodb.authdb | quote }}
{{- end }}
{{- if .Values.cerebrum.config.mongodb.username }}
- name: MONGODB_USERNAME
value: {{ .Values.cerebrum.config.mongodb.username | quote }}
{{- end }}
- name: MONGODB_PASSWORD
valueFrom:
secretKeyRef:
name: {{ template "hifiscp.fullname" . }}-mongodb-credentials
key: mongodb-password
{{- if .Values.cerebrum.dbBackup.s3EndpointUrl }}
- name: S3_ENDPOINT_URL
value: {{ .Values.cerebrum.dbBackup.s3EndpointUrl | quote }}
{{- end }}
{{- if .Values.cerebrum.dbBackup.awsAccessKeyId }}
- name: AWS_ACCESS_KEY_ID
value: {{ .Values.cerebrum.dbBackup.awsAccessKeyId | quote }}
{{- end }}
{{- if .Values.cerebrum.dbBackup.awsDefaultRegion }}
- name: AWS_DEFAULT_REGION
value: {{ .Values.cerebrum.dbBackup.awsDefaultRegion | quote }}
{{- end }}
- name: AWS_ACCESS_KEY_ID
valueFrom:
secretKeyRef:
name: {{ template "hifiscp.fullname" . }}-s3-credentials
key: access-key
- name: AWS_SECRET_ACCESS_KEY
valueFrom:
secretKeyRef:
name: {{ template "hifiscp.fullname" . }}-s3-credentials
key: access-key
restartPolicy: OnFailure
{{ end }}
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment