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.
122 lines
4.3 KiB
122 lines
4.3 KiB
3 years ago
|
{{- if .Values.abacus.processor.enabled }}
|
||
3 years ago
|
apiVersion: apps/v1
|
||
|
kind: StatefulSet
|
||
|
metadata:
|
||
3 years ago
|
name: {{ include "abacus-agent.fullname" . }}-processor
|
||
3 years ago
|
labels:
|
||
3 years ago
|
{{- include "abacus-agent.labels" . | nindent 4 }}
|
||
3 years ago
|
app.kubernetes.io/component: processor
|
||
3 years ago
|
spec:
|
||
|
selector:
|
||
|
matchLabels:
|
||
3 years ago
|
{{- include "abacus-agent.selectorLabels" . | nindent 6 }}
|
||
3 years ago
|
app.kubernetes.io/component: processor
|
||
3 years ago
|
replicas: 1
|
||
3 years ago
|
serviceName: {{ include "abacus-agent.fullname" . }}-processor
|
||
3 years ago
|
template:
|
||
|
metadata:
|
||
|
annotations:
|
||
3 years ago
|
checksum/configmap: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }}
|
||
|
{{- with .Values.podAnnotations }}
|
||
3 years ago
|
{{- toYaml . | nindent 8 }}
|
||
3 years ago
|
{{- end }}
|
||
3 years ago
|
{{- with .Values.abacus.processor.podAnnotations }}
|
||
3 years ago
|
{{ toYaml . | nindent 8 }}
|
||
|
{{- end }}
|
||
3 years ago
|
labels:
|
||
3 years ago
|
{{- include "abacus-agent.labels" . | nindent 8 }}
|
||
3 years ago
|
app.kubernetes.io/component: processor
|
||
|
{{- with .Values.podCommonLabels }}
|
||
|
{{ toYaml . | nindent 8 }}
|
||
|
{{- end }}
|
||
3 years ago
|
{{- with .Values.abacus.processor.podLabels }}
|
||
3 years ago
|
{{ toYaml . | nindent 8 }}
|
||
|
{{- end }}
|
||
3 years ago
|
spec:
|
||
|
{{- with .Values.imagePullSecrets }}
|
||
|
imagePullSecrets:
|
||
|
{{- toYaml . | nindent 8 }}
|
||
|
{{- end }}
|
||
|
terminationGracePeriodSeconds: 10
|
||
3 years ago
|
securityContext:
|
||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||
3 years ago
|
containers:
|
||
|
- name: agent
|
||
|
securityContext:
|
||
3 years ago
|
{{- toYaml .Values.securityContext | nindent 10 }}
|
||
3 years ago
|
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
|
||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||
|
command: ["./processor"]
|
||
3 years ago
|
envFrom:
|
||
|
- configMapRef:
|
||
3 years ago
|
name: {{ include "abacus-agent.fullname" . }}
|
||
3 years ago
|
- secretRef:
|
||
3 years ago
|
name: {{ include "abacus-agent.fullname" . }}-secret
|
||
3 years ago
|
- secretRef:
|
||
3 years ago
|
name: {{ include "abacus-agent.fullname" . }}-processor-secret
|
||
3 years ago
|
env:
|
||
3 years ago
|
{{- if .Values.abacus.processor.pollingInterval }}
|
||
3 years ago
|
- name: OPT_PROCESSOR_INTERVAL
|
||
3 years ago
|
value: {{ .Values.abacus.processor.pollingInterval | quote }}
|
||
3 years ago
|
{{ end }}
|
||
3 years ago
|
{{ range .Values.abacus.processor.indexonly }}
|
||
3 years ago
|
- name: OPT_PROCESSOR_INDEXON_{{ . | upper }}
|
||
|
value: "true"
|
||
|
{{ end }}
|
||
3 years ago
|
{{- if .Values.abacus.processor.s3BucketName }}
|
||
3 years ago
|
- name: OPT_PROCESSOR_S3_BUCKET
|
||
3 years ago
|
value: {{ .Values.abacus.processor.s3BucketName }}
|
||
3 years ago
|
- name: OPT_PROCESSOR_S3_REGION
|
||
3 years ago
|
value: {{ .Values.abacus.processor.s3BucketRegion }}
|
||
3 years ago
|
{{- end }}
|
||
3 years ago
|
{{- range .Values.abacus.processor.transactionSigners }}
|
||
3 years ago
|
{{- if (hasKey . "aws") }}
|
||
3 years ago
|
- name: OPT_BASE_SIGNERS_{{ .name | upper }}_TYPE
|
||
|
value: "aws"
|
||
3 years ago
|
- name: OPT_BASE_SIGNERS_{{ .name | upper }}_ID
|
||
3 years ago
|
value: {{ .aws.keyId }}
|
||
3 years ago
|
- name: OPT_BASE_SIGNERS_{{ .name | upper }}_REGION
|
||
3 years ago
|
value: {{ .aws.region }}
|
||
|
{{- end }}
|
||
3 years ago
|
{{- end }}
|
||
3 years ago
|
{{- if .Values.abacus.tracing.uri }}
|
||
3 years ago
|
- name: OPT_BASE_TRACING_JAEGER_NAME
|
||
3 years ago
|
value: {{ include "abacus-agent.fullname" . }}-processor
|
||
3 years ago
|
{{- end }}
|
||
|
resources:
|
||
3 years ago
|
{{- toYaml .Values.abacus.processor.resources | nindent 10 }}
|
||
3 years ago
|
volumeMounts:
|
||
|
- name: state
|
||
3 years ago
|
mountPath: {{ .Values.abacus.dbPath }}
|
||
3 years ago
|
ports:
|
||
|
- name: metrics
|
||
3 years ago
|
containerPort: {{ .Values.abacus.metrics.port }}
|
||
3 years ago
|
{{- with .Values.nodeSelector }}
|
||
|
nodeSelector:
|
||
|
{{- toYaml . | nindent 8 }}
|
||
|
{{- end }}
|
||
|
{{- with .Values.affinity }}
|
||
|
affinity:
|
||
|
{{- toYaml . | nindent 8 }}
|
||
|
{{- end }}
|
||
|
{{- with .Values.tolerations }}
|
||
|
tolerations:
|
||
|
{{- toYaml . | nindent 8 }}
|
||
|
{{- end }}
|
||
|
volumeClaimTemplates:
|
||
|
- metadata:
|
||
|
name: state
|
||
|
spec:
|
||
3 years ago
|
storageClassName: {{ .Values.storage.storageClass }}
|
||
|
accessModes: [ {{ .Values.storage.accessModes }} ]
|
||
3 years ago
|
{{- if .Values.abacus.processor.storage.snapshot.enabled }}
|
||
3 years ago
|
dataSource:
|
||
3 years ago
|
name: {{ .Values.abacus.processor.storage.snapshot.name }}
|
||
3 years ago
|
kind: VolumeSnapshot
|
||
|
apiGroup: snapshot.storage.k8s.io
|
||
|
{{- end }}
|
||
3 years ago
|
resources:
|
||
|
requests:
|
||
3 years ago
|
storage: {{ .Values.abacus.processor.storage.size }}
|
||
3 years ago
|
{{- end }}
|