You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
1.3 KiB
38 lines
1.3 KiB
apiVersion: batch/v1beta1
|
|
kind: CronJob
|
|
metadata:
|
|
name: {{ include "pv-resizer.fullname" . }}
|
|
labels:
|
|
{{- include "pv-resizer.labels" . | nindent 4 }}
|
|
spec:
|
|
# generate a random backup time between 1 and 5 AM
|
|
schedule: {{ .Values.schedule }}
|
|
concurrencyPolicy: Forbid
|
|
jobTemplate:
|
|
spec:
|
|
template:
|
|
metadata:
|
|
labels:
|
|
{{- include "pv-resizer.selectorLabels" . | nindent 12 }}
|
|
spec:
|
|
serviceAccountName: {{ include "pv-resizer.serviceAccountName" . }}
|
|
{{- with .Values.imagePullSecrets }}
|
|
imagePullSecrets:
|
|
{{- toYaml . | nindent 12 }}
|
|
{{- end }}
|
|
securityContext:
|
|
{{- toYaml .Values.podSecurityContext | nindent 12 }}
|
|
containers:
|
|
- name: {{ .Release.Name }}
|
|
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
|
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
|
command: [ "/check_full_pvs.sh", "-f" ]
|
|
restartPolicy: OnFailure
|
|
{{- with .Values.nodeSelector }}
|
|
nodeSelector:
|
|
{{- toYaml . | nindent 12 }}
|
|
{{- end }}
|
|
{{- with .Values.tolerations }}
|
|
tolerations:
|
|
{{- toYaml . | nindent 12 }}
|
|
{{- end }}
|
|
|