feat(helm): add helm chart
This commit is contained in:
1 parent
5cab1cd96d
commit
86bfdd5622
9 files changed
+247
-73
No files matched your search
@@ -8,6 +8,11 @@ spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "pod-cleaner.selectorLabels" . | nindent 6 }}
|
||||
{{- if .Values.updateStrategy }}
|
||||
updateStrategy:
|
||||
{{ toYaml .Values.updateStrategy | nindent 4 | trim }}
|
||||
{{- end }}
|
||||
revisionHistoryLimit: {{ .Values.revisionHistoryLimit }}
|
||||
template:
|
||||
metadata:
|
||||
{{- with .Values.podAnnotations }}
|
||||
@@ -17,7 +22,7 @@ spec:
|
||||
labels:
|
||||
{{- include "pod-cleaner.selectorLabels" . | nindent 8 }}
|
||||
spec:
|
||||
{{- with .Values.imagePullSecrets }}
|
||||
{{- with .Values.image.pullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
@@ -31,33 +36,40 @@ spec:
|
||||
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
args:
|
||||
- "--metric-path=/metrics"
|
||||
- "--metric-path={{ .Values.podMonitor.path }}"
|
||||
- "--metric-port=0.0.0.0:{{ .Values.service.port }}"
|
||||
- "--log-file={{ .Values.podCleaner.logfile }}"
|
||||
- "--log={{ .Values.podCleaner.logLevel }}"
|
||||
ports:
|
||||
- name: http-metric
|
||||
- name: {{ include "pod-cleaner.metrics.portName" . }}
|
||||
containerPort: {{ .Values.service.port }}
|
||||
protocol: TCP
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /metrics
|
||||
port: http-metric
|
||||
path: {{ .Values.podMonitor.path }}
|
||||
port: {{ include "pod-cleaner.metrics.portName" . }}
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /metrics
|
||||
port: http-metric
|
||||
path: {{ .Values.podMonitor.path }}
|
||||
port: {{ include "pod-cleaner.metrics.portName" . }}
|
||||
resources:
|
||||
{{- toYaml .Values.resources | nindent 12 }}
|
||||
{{- if or .Values.nodeAffinity }}
|
||||
affinity:
|
||||
{{- toYaml .Values.nodeAffinity | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.nodeSelector }}
|
||||
nodeSelector:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.affinity }}
|
||||
affinity:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{ tpl (toYaml . ) $ | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.tolerations }}
|
||||
tolerations:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- tpl (toYaml . ) $ | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.topologySpreadConstraints }}
|
||||
topologySpreadConstraints: {{ tpl (toYaml . ) $ | nindent 8 }}
|
||||
{{- end }}
|
||||
serviceAccountName: {{ template "pod-cleaner.serviceAccountName" . }}
|
||||
{{- if .Values.priorityClassName }}
|
||||
priorityClassName: {{ .Values.priorityClassName | quote }}
|
||||
{{- end }}
|
||||
Reference in new issue
Block a user