1 # Copyright © 2020 Bitnami, AT&T, Amdocs, Bell Canada, highstreet technologies
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://www.apache.org/licenses/LICENSE-2.0
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14 {{- if .Values.enabled }}
15 {{- range $kind, $enabled := .Values.hooks }}
21 name: {{ include "common.fullname" . }}-curator-on-{{ $kind }}
22 namespace: {{ include "common.namespace" . }}
23 labels: {{- include "common.labels" . | nindent 2 }}
26 "helm.sh/hook": post-{{ $kind }}
27 "helm.sh/hook-weight": "1"
28 {{- if $.Values.cronjob.annotations }}
29 {{ toYaml $.Values.cronjob.annotations | indent 4 }}
33 metadata: {{- include "common.templateMetadata" . | nindent 6 }}
38 name: {{ template "common.fullname" (dict "suffix" "curator" "dot" .) }}
39 {{- if $.Values.extraVolumes }}
40 {{ toYaml $.Values.extraVolumes | indent 8 }}
43 {{- if $.Values.priorityClassName }}
44 priorityClassName: "{{ $.Values.priorityClassName }}"
47 - name: {{ template "common.fullname" . }}-curator
48 image: {{printf "%s/%s" (include "common.repository" .) .Values.image }}
49 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
52 mountPath: /etc/es-curator
53 {{- if $.Values.extraVolumeMounts }}
54 {{ toYaml $.Values.extraVolumeMounts | indent 12 }}
56 command: [ "curator" ]
57 args: [ "--config", "/etc/es-curator/config.yml", "/etc/es-curator/action_file.yml" ]
59 {{ toYaml $.Values.resources | indent 12 }}
60 {{- with $.Values.nodeSelector }}
62 {{ toYaml . | indent 8 }}
64 {{- with $.Values.affinity }}
66 {{ toYaml . | indent 8 }}
68 {{- with $.Values.tolerations }}
70 {{ toYaml . | indent 8 }}