Commit ccf326e7 authored by Thomas Beermann's avatar Thomas Beermann
Browse files

add cronjob definition for availability checker

parent 61695678
Pipeline #107975 passed with stages
in 18 seconds
{{- if .Values.cerebrum.availabilityChecker.enabled -}}
apiVersion: batch/v1beta1
kind: CronJob
metadata:
name: {{ .Release.Name }}-availibilty-checker
labels:
app: {{ template "hifiscp.name" . }}-availibilty-checker
chart: {{ template "hifiscp.chart" . }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
spec:
schedule: "{{ .Values.cerebrum.availabilityChecker.schedule }}"
jobTemplate:
spec:
template:
spec:
containers:
- name: availibilty-checker
image: {{ .Values.cerebrum.availabilityChecker.image.repository }}:{{ .Values.cerebrum.availabilityChecker.image.tag }}
imagePullPolicy: {{ .Values.cerebrum.availabilityChecker.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
restartPolicy: OnFailure
{{ end }}
\ No newline at end of file
......@@ -2,13 +2,21 @@
cerebrum:
replicas: 1
availabilityChecker:
enabled: 0
schedule: "*/10 * * * *"
image:
repository: registry.hzdr.de/hifis/cloud/access-layer/portal/availability-checker
tag: latest
pullPolicy: Always
image:
repository: registry.hzdr.de/helmholtz-cloud-portal/cerebrum
repository: registry.hzdr.de/hifis/cloud/access-layer/portal/cerebrum
tag: latest
pullPolicy: Always
rollingUpdate:
maxUnavailable: 0
maxUnavailable: 1
maxSurge: 1
service:
......@@ -29,7 +37,7 @@ cerebrum:
readinessProbe:
enabled: true
initialDelaySeconds: 30
initialDelaySeconds: 60
periodSeconds: 10
timeoutSeconds: 5
failureThreshold: 6
......@@ -65,12 +73,12 @@ webapp:
replicas: 1
image:
repository: registry.hzdr.de/helmholtz-cloud-portal/webapp
repository: registry.hzdr.de/hifis/cloud/access-layer/portal/webapp
tag: latest
pullPolicy: Always
rollingUpdate:
maxUnavailable: 0
maxUnavailable: 1
maxSurge: 1
service:
......
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