k8s-manifests/rds/base/charts/jaeger/templates/ingester-deploy.yaml

132 lines
4.5 KiB
YAML

{{- if .Values.ingester.enabled -}}
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "jaeger.fullname" . }}-ingester
namespace: {{ .Release.Namespace }}
labels:
{{- include "jaeger.labels" . | nindent 4 }}
app.kubernetes.io/component: ingester
{{- if .Values.ingester.annotations }}
annotations:
{{- toYaml .Values.ingester.annotations | nindent 4 }}
{{- end }}
spec:
{{- if not .Values.ingester.autoscaling.enabled }}
replicas: {{ .Values.ingester.replicaCount }}
{{- end }}
selector:
matchLabels:
{{- include "jaeger.selectorLabels" . | nindent 6 }}
app.kubernetes.io/component: ingester
strategy:
type: Recreate
template:
metadata:
annotations:
{{- if .Values.ingester.podAnnotations }}
{{- toYaml .Values.ingester.podAnnotations | nindent 8 }}
{{- end }}
labels:
{{- include "jaeger.selectorLabels" . | nindent 8 }}
app.kubernetes.io/component: ingester
{{- if .Values.ingester.podLabels }}
{{- toYaml .Values.ingester.podLabels | nindent 8 }}
{{- end }}
spec:
securityContext:
{{- toYaml .Values.ingester.podSecurityContext | nindent 8 }}
{{- with .Values.ingester.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
nodeSelector:
{{- toYaml .Values.ingester.nodeSelector | nindent 8 }}
{{- if .Values.ingester.tolerations }}
tolerations:
{{- toYaml .Values.ingester.tolerations | nindent 8 }}
{{- end }}
containers:
- name: {{ include "jaeger.fullname" . }}-ingester
securityContext:
{{- toYaml .Values.ingester.securityContext | nindent 10 }}
image: {{ .Values.ingester.image }}:{{ .Values.tag }}
imagePullPolicy: {{ .Values.ingester.pullPolicy }}
args:
{{- range $key, $value := .Values.ingester.cmdlineParams }}
{{- if $value }}
- --{{ $key }}={{ $value }}
{{- else }}
- --{{ $key }}
{{- end }}
{{- end }}
{{- include "storage.cmdArgs" . | nindent 10 }}
env:
{{- if .Values.ingester.extraEnv }}
{{- toYaml .Values.ingester.extraEnv | nindent 10 }}
{{- end }}
- name: SPAN_STORAGE_TYPE
value: {{ .Values.storage.type }}
{{- include "storage.env" . | nindent 10 }}
- name: KAFKA_CONSUMER_BROKERS
value: {{ include "helm-toolkit.utils.joinListWithComma" .Values.storage.kafka.brokers }}
- name: KAFKA_CONSUMER_TOPIC
value: {{ .Values.storage.kafka.topic }}
- name: KAFKA_CONSUMER_AUTHENTICATION
value: {{ .Values.storage.kafka.authentication }}
ports:
- containerPort: 14270
name: admin
protocol: TCP
readinessProbe:
httpGet:
path: /
port: admin
livenessProbe:
httpGet:
path: /
port: admin
resources:
{{- toYaml .Values.ingester.resources | nindent 10 }}
volumeMounts:
{{- range .Values.ingester.extraConfigmapMounts }}
- name: {{ .name }}
mountPath: {{ .mountPath }}
subPath: {{ .subPath }}
readOnly: {{ .readOnly }}
{{- end }}
{{- range .Values.ingester.extraSecretMounts }}
- name: {{ .name }}
mountPath: {{ .mountPath }}
subPath: {{ .subPath }}
readOnly: {{ .readOnly }}
{{- end }}
{{- if .Values.storage.cassandra.tls.enabled }}
- name: {{ .Values.storage.cassandra.tls.secretName }}
mountPath: "/cassandra-tls/ca-cert.pem"
subPath: "ca-cert.pem"
readOnly: true
- name: {{ .Values.storage.cassandra.tls.secretName }}
mountPath: "/cassandra-tls/client-cert.pem"
subPath: "client-cert.pem"
readOnly: true
- name: {{ .Values.storage.cassandra.tls.secretName }}
mountPath: "/cassandra-tls/client-key.pem"
subPath: "client-key.pem"
readOnly: true
{{- end }}
dnsPolicy: {{ .Values.ingester.dnsPolicy }}
restartPolicy: Always
volumes:
{{- range .Values.ingester.extraConfigmapMounts }}
- name: {{ .name }}
configMap:
name: {{ .configMap }}
{{- end }}
{{- range .Values.ingester.extraSecretMounts }}
- name: {{ .name }}
secret:
secretName: {{ .secretName }}
{{- end }}
{{- end -}}