mirror of https://git.rancher.io/charts
73 lines
2.7 KiB
Diff
73 lines
2.7 KiB
Diff
|
--- charts-original/templates/deployment.yaml
|
||
|
+++ charts/templates/deployment.yaml
|
||
|
@@ -2,8 +2,8 @@
|
||
|
kind: Deployment
|
||
|
metadata:
|
||
|
name: {{ include "prom2teams.fullname" . }}
|
||
|
- labels:
|
||
|
-{{ include "prom2teams.labels" . | indent 4 }}
|
||
|
+ namespace: {{ include "prom2teams.namespace" . }}
|
||
|
+ labels: {{ include "prom2teams.labels" . | nindent 4 }}
|
||
|
spec:
|
||
|
replicas: {{ .Values.replicaCount }}
|
||
|
selector:
|
||
|
@@ -16,17 +16,17 @@
|
||
|
app.kubernetes.io/name: {{ include "prom2teams.name" . }}
|
||
|
app.kubernetes.io/instance: {{ .Release.Name }}
|
||
|
spec:
|
||
|
+ serviceAccountName: {{ include "prom2teams.fullname" . }}
|
||
|
{{- with .Values.imagePullSecrets }}
|
||
|
- imagePullSecrets:
|
||
|
- {{- toYaml . | nindent 8 }}
|
||
|
+ imagePullSecrets: {{ toYaml . | nindent 8 }}
|
||
|
{{- end }}
|
||
|
volumes:
|
||
|
- name: config
|
||
|
configMap:
|
||
|
- name: prom2teams-config
|
||
|
+ name: {{ include "prom2teams.fullname" . }}
|
||
|
containers:
|
||
|
- name: {{ .Chart.Name }}
|
||
|
- image: "{{ .Values.image.repository }}:{{ default .Chart.AppVersion .Values.image.tag }}"
|
||
|
+ image: {{ include "system_default_registry" . }}{{ .Values.image.repository }}:{{ .Values.image.tag }}
|
||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||
|
ports:
|
||
|
- name: http
|
||
|
@@ -46,8 +46,7 @@
|
||
|
value: {{ .Values.prom2teams.connector | quote }}
|
||
|
- name: PROM2TEAMS_GROUP_ALERTS_BY
|
||
|
value: {{ .Values.prom2teams.group_alerts_by | quote }}
|
||
|
- resources:
|
||
|
- {{- toYaml .Values.resources | nindent 12 }}
|
||
|
+ resources: {{ toYaml .Values.resources | nindent 12 }}
|
||
|
{{- if .Values.securityContext.enabled }}
|
||
|
securityContext:
|
||
|
privileged: false
|
||
|
@@ -57,18 +56,17 @@
|
||
|
drop:
|
||
|
- ALL
|
||
|
{{- end }}
|
||
|
- {{- with .Values.nodeSelector }}
|
||
|
- nodeSelector:
|
||
|
- {{- toYaml . | nindent 8 }}
|
||
|
+ nodeSelector: {{ include "linux-node-selector" . | nindent 8 }}
|
||
|
+ {{- if .Values.nodeSelector }}
|
||
|
+ {{- toYaml .Values.nodeSelector | nindent 8 }}
|
||
|
{{- end }}
|
||
|
{{- with .Values.affinity }}
|
||
|
- affinity:
|
||
|
- {{- toYaml . | nindent 8 }}
|
||
|
- {{- end }}
|
||
|
- {{- with .Values.tolerations }}
|
||
|
- tolerations:
|
||
|
- {{- toYaml . | nindent 8 }}
|
||
|
+ affinity: {{ toYaml . | nindent 8 }}
|
||
|
{{- end }}
|
||
|
+ tolerations: {{ include "linux-node-tolerations" . | nindent 8 }}
|
||
|
+ {{- if .Values.tolerations }}
|
||
|
+ {{- toYaml .Values.tolerations | nindent 8 }}
|
||
|
+ {{- end }}
|
||
|
{{- if .Values.securityContext.enabled }}
|
||
|
securityContext:
|
||
|
runAsNonRoot: {{ if eq (int .Values.securityContext.runAsUser) 0 }}false{{ else }}true{{ end }}
|